diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/outputapi.h | 2 | ||||
-rw-r--r-- | src/tvtime.c | 2 | ||||
-rw-r--r-- | src/tvtimeconf.c | 10 | ||||
-rw-r--r-- | src/tvtimeconf.h | 1 | ||||
-rw-r--r-- | src/xcommon.c | 17 | ||||
-rw-r--r-- | src/xcommon.h | 2 | ||||
-rw-r--r-- | src/xvoutput.c | 4 |
7 files changed, 20 insertions, 18 deletions
diff --git a/src/outputapi.h b/src/outputapi.h index 2725e4f..d5aa284 100644 --- a/src/outputapi.h +++ b/src/outputapi.h @@ -28,7 +28,7 @@ typedef struct output_api_s { - int (* init)( const char *user_geometry, int aspect, int squarepixel, int verbose ); + int (* init)( const char *user_geometry, int aspect, int squarepixel, int border, int verbose ); int (* set_input_size)( int inputwidth, int inputheight ); diff --git a/src/tvtime.c b/src/tvtime.c index 1d58274..fb94831 100644 --- a/src/tvtime.c +++ b/src/tvtime.c @@ -1250,7 +1250,7 @@ int tvtime_main( rtctimer_t *rtctimer, int read_stdin, int realtime, } if( !output->init( config_get_geometry( ct ), sixteennine, - config_get_square_pixels( ct ), verbose ) ) { + config_get_square_pixels( ct ), !config_get_borderless(ct), verbose ) ) { /* Error messages are driver specific. */ return 1; } diff --git a/src/tvtimeconf.c b/src/tvtimeconf.c index 4d9e25b..cf6eab5 100644 --- a/src/tvtimeconf.c +++ b/src/tvtimeconf.c @@ -946,14 +946,14 @@ int config_parse_tvtime_command_line( config_t *ct, int argc, char **argv ) int c; if( argc ) { - while( (c = getopt_long( argc, argv, "aAhkmMsSvV:F:r:g:I:d:b:i:c:n:D:f:x:X:t:l:Qg:", + while( (c = getopt_long( argc, argv, "aAhkmMsSvV:F:r:g:I:d:b:i:c:n:D:f:x:X:t:Ll:Qg:", long_options, &option_index )) != -1 ) { switch( c ) { case 'a': ct->aspect = 1; break; case 'A': ct->aspect = 0; break; case 'k': ct->slave_mode = 1; break; case 'm': ct->fullscreen = 1; break; - //case 'l': ct->borderless = 1; break; + case 'L': ct->borderless = 1; break; case 'M': ct->fullscreen = 0; break; case 's': ct->debug = 1; break; case 'S': saveoptions = 1; break; @@ -1083,7 +1083,7 @@ int config_parse_tvtime_config_command_line( config_t *ct, int argc, char **argv { "device", 2, 0, 'd' }, { "mixer", 1, 0, 'x' }, { "fullscreen", 0, 0, 'm' }, - { "borderless", 0, 0, 'l' }, + { "borderless", 0, 0, 'L' }, { "window", 0, 0, 'M' }, { "widescreen", 0, 0, 'a' }, { "nowidescreen", 0, 0, 'A' }, @@ -1104,13 +1104,13 @@ int config_parse_tvtime_config_command_line( config_t *ct, int argc, char **argv } while( (c = getopt_long( argc, argv, - "aAhmMF:g:I:d:b:i:c:n:D:f:x:t:l:R:p:P", + "aAhmMF:g:I:d:b:i:c:n:D:f:x:t:Ll:R:p:P", long_options, &option_index )) != -1 ) { switch( c ) { case 'a': ct->aspect = 1; break; case 'A': ct->aspect = 0; break; case 'm': ct->fullscreen = 1; break; - //case 'l': ct->borderless = 1; break; + case 'L': ct->borderless = 1; break; case 'M': ct->fullscreen = 0; break; case 'F': if( ct->config_filename ) free( ct->config_filename ); filename_specified = 1; diff --git a/src/tvtimeconf.h b/src/tvtimeconf.h index 91a7b1b..030d885 100644 --- a/src/tvtimeconf.h +++ b/src/tvtimeconf.h @@ -148,6 +148,7 @@ int config_get_verbose( config_t *ct ); int config_get_send_fields( config_t *ct ); int config_get_fullscreen_position( config_t *ct ); int config_get_debug( config_t *ct ); +int config_get_borderless( config_t *ct ); const char *config_get_geometry( config_t *ct ); int config_get_inputwidth( config_t *ct ); int config_get_aspect( config_t *ct ); diff --git a/src/xcommon.c b/src/xcommon.c index 865d612..0d26421 100644 --- a/src/xcommon.c +++ b/src/xcommon.c @@ -833,7 +833,7 @@ static void calculate_video_area( void ) } -int xcommon_open_display( const char *user_geometry, int aspect, int verbose ) +int xcommon_open_display( const char *user_geometry, int aspect, int border, int verbose ) { Pixmap curs_pix; XEvent xev; @@ -1065,13 +1065,14 @@ int xcommon_open_display( const char *user_geometry, int aspect, int verbose ) Atom prop = None; MWMHints mwmhints; -// if config_get_borderless - prop = XInternAtom( display, "_MOTIF_WM_INFO", True ); - if( prop == None ) { - mwmhints.flags = 0; - } else { - mwmhints.flags = MWM_HINTS_DECORATIONS; - mwmhints.decorations = 0; + if (!border) { + prop = XInternAtom( display, "_MOTIF_WM_INFO", True ); + if( prop == None ) { + mwmhints.flags = 0; + } else { + mwmhints.flags = MWM_HINTS_DECORATIONS; + mwmhints.decorations = 0; + } } if( mwmhints.flags ) { diff --git a/src/xcommon.h b/src/xcommon.h index d48a53e..0e10ddb 100644 --- a/src/xcommon.h +++ b/src/xcommon.h @@ -68,7 +68,7 @@ typedef struct _mwmhints { #define MWM_INPUT_FULL_APPLICATION_MODAL 3 #define PROP_MWM_HINTS_ELEMENTS 5 -int xcommon_open_display( const char *user_geometry, int aspect, int verbose ); +int xcommon_open_display( const char *user_geometry, int aspect, int border, int verbose ); void xcommon_close_display( void ); Display *xcommon_get_display( void ); diff --git a/src/xvoutput.c b/src/xvoutput.c index e1b5e9e..d9d9656 100644 --- a/src/xvoutput.c +++ b/src/xvoutput.c @@ -293,7 +293,7 @@ static int get_colourkey( void ) return 0; } -static int xv_init( const char *user_geometry, int aspect, int squarepixel, int verbose ) +static int xv_init( const char *user_geometry, int aspect, int squarepixel, int border, int verbose ) { xvoutput_verbose = verbose; @@ -303,7 +303,7 @@ static int xv_init( const char *user_geometry, int aspect, int squarepixel, int } xcommon_set_square_pixel_mode( squarepixel ); - if( !xcommon_open_display( user_geometry, aspect, verbose ) ) { + if( !xcommon_open_display( user_geometry, aspect, border, verbose ) ) { return 0; } display = xcommon_get_display(); |