aboutsummaryrefslogtreecommitdiffhomepage
path: root/libvo
diff options
context:
space:
mode:
authorGravatar arpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-08-21 21:24:23 +0000
committerGravatar arpi <arpi@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-08-21 21:24:23 +0000
commit1dd16637fb3f63f630fd093b0276410ca9d53f95 (patch)
tree4ef1d247fa94ea4ebb078b8d34eff8ec8137ac20 /libvo
parentf294139b30d1924f678488b251f276444b562dd5 (diff)
this piece of code should prevent major fullscreen screwups, which can
be otherwise triggered by rapid switching to fullscreen and back. patch by Jindrich Makovicka <makovick@kmlinux.fjfi.cvut.cz> git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@7058 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'libvo')
-rw-r--r--libvo/x11_common.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/libvo/x11_common.c b/libvo/x11_common.c
index b51b272d85..2d9e5438d1 100644
--- a/libvo/x11_common.c
+++ b/libvo/x11_common.c
@@ -588,6 +588,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;
vo_dwidth=Event.xconfigure.width;
vo_dheight=Event.xconfigure.height;
#if 0
@@ -756,6 +758,9 @@ void vo_x11_fullscreen( void )
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; }