Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 34709 Details for
Bug 55969
Mplayer 1.0pre4 fullscreen mode doesn't work correctly with metacity
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
the patch made from mplayer-cvs
MPlayer-1.0pre4-ewmh.patch (text/plain), 3.99 KB, created by
Alexander Kreuzer
on 2004-07-03 07:46:28 UTC
(
hide
)
Description:
the patch made from mplayer-cvs
Filename:
MIME Type:
Creator:
Alexander Kreuzer
Created:
2004-07-03 07:46:28 UTC
Size:
3.99 KB
patch
obsolete
>diff -Naur MPlayer-1.0pre4.orig/help/help_mp-en.h MPlayer-1.0pre4/help/help_mp-en.h >--- MPlayer-1.0pre4.orig/help/help_mp-en.h 2004-07-03 15:50:26.349726368 +0200 >+++ MPlayer-1.0pre4/help/help_mp-en.h 2004-07-03 15:59:09.934129440 +0200 >@@ -360,6 +360,9 @@ > #define MSGTR_MovieAspectIsSet "Movie-Aspect is %.2f:1 - prescaling to correct movie aspect.\n" > #define MSGTR_MovieAspectUndefined "Movie-Aspect is undefined - no prescaling applied.\n" > >+// x11_common.c >+#define MSGTR_EwmhFullscreenStateFailed "\nX11: Couldn't send EWMH fullscreen Event!\n" >+ > // ====================== GUI messages/buttons ======================== > > #ifdef HAVE_NEW_GUI >diff -Naur MPlayer-1.0pre4.orig/libvo/x11_common.c MPlayer-1.0pre4/libvo/x11_common.c >--- MPlayer-1.0pre4.orig/libvo/x11_common.c 2004-07-03 15:50:26.216746584 +0200 >+++ MPlayer-1.0pre4/libvo/x11_common.c 2004-07-03 15:57:09.022510800 +0200 >@@ -14,6 +14,7 @@ > #include <unistd.h> > #include <sys/mman.h> > #include <signal.h> >+#include <assert.h> > > #include "video_out.h" > #include "aspect.h" >@@ -117,6 +118,47 @@ > > static int vo_x11_get_fs_type(int supported); > >+/* >+ * Sends the EWMH fullscreen state event. >+ * >+ * action: could be on of _NET_WM_STATE_REMOVE -- remove state >+ * _NET_WM_STATE_ADD -- add state >+ * _NET_WM_STATE_TOGGLE -- toggle >+ */ >+void vo_x11_ewmh_fullscreen( int action ) >+{ >+ assert( action == _NET_WM_STATE_REMOVE || >+ action == _NET_WM_STATE_ADD || >+ action == _NET_WM_STATE_TOGGLE ); >+ >+ if ( vo_fs_type & vo_wm_FULLSCREEN ) >+ { >+ XEvent xev; >+ >+ /* init X event structure for _NET_WM_FULLSCREEN client msg */ >+ xev.xclient.type = ClientMessage; >+ xev.xclient.serial = 0; >+ xev.xclient.send_event = True; >+ xev.xclient.message_type = XInternAtom( mDisplay, >+ "_NET_WM_STATE", False ); >+ xev.xclient.window = vo_window; >+ xev.xclient.format = 32; >+ xev.xclient.data.l[0] = action; >+ xev.xclient.data.l[1] = XInternAtom( mDisplay, >+ "_NET_WM_STATE_FULLSCREEN", False ); >+ xev.xclient.data.l[2] = 0; >+ xev.xclient.data.l[3] = 0; >+ xev.xclient.data.l[4] = 0; >+ >+ /* finally send that damn thing */ >+ if ( !XSendEvent( mDisplay, DefaultRootWindow( mDisplay ), False, >+ SubstructureRedirectMask | SubstructureNotifyMask, &xev ) ) >+ { >+ mp_msg( MSGT_VO,MSGL_ERR, MSGTR_EwmhFullscreenStateFailed ); >+ } >+ } >+} >+ > void vo_hidecursor ( Display *disp , Window win ) > { > Cursor no_ptr; >@@ -1062,11 +1104,14 @@ > > if ( vo_fs ){ > // fs->win >+ vo_x11_ewmh_fullscreen( _NET_WM_STATE_REMOVE ); // removes fullscreen state if wm supports EWMH >+ > 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 >+ vo_x11_ewmh_fullscreen( _NET_WM_STATE_ADD ); // sends fullscreen state to be added if wm supports EWMH > if(vo_old_width && > (vo_dwidth==vo_screenwidth && vo_dwidth!=vo_old_width) && > (vo_dheight==vo_screenheight && vo_dheight!=vo_old_height) ) return; >diff -Naur MPlayer-1.0pre4.orig/libvo/x11_common.h MPlayer-1.0pre4/libvo/x11_common.h >--- MPlayer-1.0pre4.orig/libvo/x11_common.h 2004-07-03 15:50:26.212747192 +0200 >+++ MPlayer-1.0pre4/libvo/x11_common.h 2004-07-03 15:55:03.534587864 +0200 >@@ -14,6 +14,12 @@ > #define vo_wm_BELOW 16 > #define vo_wm_NETWM (vo_wm_FULLSCREEN | vo_wm_STAYS_ON_TOP | vo_wm_ABOVE | vo_wm_BELOW) > >+/* EWMH state actions, see >+ http://freedesktop.org/Standards/wm-spec/index.html#id2768769 */ >+#define _NET_WM_STATE_REMOVE 0 /* remove/unset property */ >+#define _NET_WM_STATE_ADD 1 /* add/set property */ >+#define _NET_WM_STATE_TOGGLE 2 /* toggle property */ >+ > extern int metacity_hack; > extern int vo_fsmode; > >@@ -62,6 +68,7 @@ > int img_width, int img_height, int use_fs); > extern void vo_x11_clearwindow( Display *mDisplay, Window vo_window ); > extern void vo_x11_ontop(); >+extern void vo_x11_ewmh_fullscreen( int action ); > > #endif >
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 55969
: 34709 |
34710