diff options
author | arpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2002-09-18 01:22:03 +0000 |
---|---|---|
committer | arpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2> | 2002-09-18 01:22:03 +0000 |
commit | 766e2f7af34bcc3a9f38a94e97b5d65120724ed4 (patch) | |
tree | e1407e08c093e8f088161c63ec5f4fd55c633ea5 | |
parent | 7ac030210a28505b0816d9a14b2f6613a2d2aa31 (diff) |
d_width==screenwidth && -fs hopefully fixed
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@7436 b3059339-0415-0410-9bf9-f77b7e298cf2
-rw-r--r-- | libvo/video_out.c | 5 | ||||
-rw-r--r-- | libvo/video_out.h | 5 | ||||
-rw-r--r-- | libvo/x11_common.c | 33 |
3 files changed, 24 insertions, 19 deletions
diff --git a/libvo/video_out.c b/libvo/video_out.c index c8bb14b5f1..d6173e8dba 100644 --- a/libvo/video_out.c +++ b/libvo/video_out.c @@ -30,11 +30,6 @@ int vo_dwidth=0; int vo_dheight=0; int vo_dbpp=0; -int vo_old_x = 0; -int vo_old_y = 0; -int vo_old_width = 0; -int vo_old_height = 0; - int vo_doublebuffering = 0; int vo_vsync = 0; int vo_fs = 0; diff --git a/libvo/video_out.h b/libvo/video_out.h index 9f55339838..29dc2fd496 100644 --- a/libvo/video_out.h +++ b/libvo/video_out.h @@ -170,11 +170,6 @@ extern int vo_dwidth; extern int vo_dheight; extern int vo_dbpp; -extern int vo_old_x; -extern int vo_old_y; -extern int vo_old_width; -extern int vo_old_height; - extern int vo_doublebuffering; extern int vo_directrendering; extern int vo_vsync; diff --git a/libvo/x11_common.c b/libvo/x11_common.c index 35c6fe7a69..acb5bb574a 100644 --- a/libvo/x11_common.c +++ b/libvo/x11_common.c @@ -66,6 +66,12 @@ int WinID=-1; int vo_mouse_autohide = 0; int vo_wm_type = -1; +static int vo_old_x = 0; +static int vo_old_y = 0; +static int vo_old_width = 0; +static int vo_old_height = 0; + + #ifdef HAVE_XINERAMA int xinerama_screen = 0; int xinerama_x = 0; @@ -495,6 +501,7 @@ void vo_x11_uninit() vo_window=None; } vo_fs=0; + vo_old_width=vo_old_height=0; } } @@ -529,8 +536,8 @@ int vo_x11_check_events(Display *mydisplay){ ret|=VO_EVENT_EXPOSE; break; case ConfigureNotify: - if (!vo_fs && (Event.xconfigure.width == vo_screenwidth || Event.xconfigure.height == vo_screenheight)) break; - if (vo_fs && Event.xconfigure.width != vo_screenwidth && Event.xconfigure.height != vo_screenheight) break; +// if (!vo_fs && (Event.xconfigure.width == vo_screenwidth || Event.xconfigure.height == vo_screenheight)) break; +// if (vo_fs && Event.xconfigure.width != vo_screenwidth && Event.xconfigure.height != vo_screenheight) break; vo_dwidth=Event.xconfigure.width; vo_dheight=Event.xconfigure.height; #if 0 @@ -693,16 +700,24 @@ void vo_x11_setlayer( int layer ) void vo_x11_fullscreen( void ) { - int x=0,y=0,w=vo_screenwidth,h=vo_screenheight; + int x,y,w,h; if ( WinID >= 0 ) return; - if ( !vo_fs && (vo_dwidth == vo_screenwidth || vo_dheight == vo_screenheight)) return; - if ( vo_fs && vo_dwidth != vo_screenwidth && vo_dheight != vo_screenheight) return; - - if ( vo_fs ) - { vo_fs=VO_FALSE; x=vo_old_x; y=vo_old_y; w=vo_old_width; h=vo_old_height; } - else { vo_fs=VO_TRUE; vo_old_x=vo_dx; vo_old_y=vo_dy; vo_old_width=vo_dwidth; vo_old_height=vo_dheight; } + if ( vo_fs ){ + // fs->win + if(vo_dwidth != vo_screenwidth && vo_dheight != vo_screenheight) return; + vo_fs=VO_FALSE; + x=vo_old_x; y=vo_old_y; w=vo_old_width; h=vo_old_height; + } else { + // win->fs + if(vo_old_width && + (vo_dwidth==vo_screenwidth && vo_dwidth!=vo_old_width) && + (vo_dheight==vo_screenheight && vo_dheight!=vo_old_height) ) return; + vo_fs=VO_TRUE; + vo_old_x=vo_dx; vo_old_y=vo_dy; vo_old_width=vo_dwidth; vo_old_height=vo_dheight; + x=0; y=0; w=vo_screenwidth; h=vo_screenheight; + } vo_x11_decoration( mDisplay,vo_window,(vo_fs) ? 0 : 1 ); vo_x11_sizehint( x,y,w,h,0 ); |