summaryrefslogtreecommitdiffstats
path: root/Gui
diff options
context:
space:
mode:
authorpontscho <pontscho@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-10-01 14:37:01 +0000
committerpontscho <pontscho@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-10-01 14:37:01 +0000
commit690bccca999e83ff636a4d935e9c5212871ac1e2 (patch)
treed7b7bb2f6d49f4ce42c1072cb20790dd5b45cb6b /Gui
parent3ef4629545772e39aeed57195521e78fe5c08aaa (diff)
downloadmpv-690bccca999e83ff636a4d935e9c5212871ac1e2.tar.bz2
mpv-690bccca999e83ff636a4d935e9c5212871ac1e2.tar.xz
_NET_WM_FULLSCREEN support
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@7573 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'Gui')
-rw-r--r--Gui/wm/ws.c10
1 files changed, 8 insertions, 2 deletions
diff --git a/Gui/wm/ws.c b/Gui/wm/ws.c
index ff57a1c856..a30eb2d7bd 100644
--- a/Gui/wm/ws.c
+++ b/Gui/wm/ws.c
@@ -776,7 +776,7 @@ void wsSetLayer( Display * wsDisplay, Window win, int layer )
Atom type;
int format;
unsigned long nitems, bytesafter;
- unsigned char * args = NULL;
+ Atom * args = NULL;
if ( wsWMType == wsWMIceWM )
{
@@ -794,15 +794,21 @@ void wsSetLayer( Display * wsDisplay, Window win, int layer )
type=XInternAtom( wsDisplay,"_NET_SUPPORTED",False );
if ( Success == XGetWindowProperty( wsDisplay,wsRootWin,type,0,65536 / sizeof( int32_t ),False,AnyPropertyType,&type,&format,&nitems,&bytesafter,&args ) && nitems > 0 )
{
+ int i;
XEvent e;
+
e.xclient.type=ClientMessage;
e.xclient.message_type=XInternAtom( wsDisplay,"_NET_WM_STATE",False );
e.xclient.display=wsDisplay;
e.xclient.window=win;
e.xclient.format=32;
e.xclient.data.l[0]=layer;
+
e.xclient.data.l[1]=XInternAtom( wsDisplay,"_NET_WM_STATE_STAYS_ON_TOP",False );
-// e.xclient.data.l[1]=XInternAtom( wsDisplay,"_NET_WM_STATE_FULLSCREEN",False );
+ type=XInternAtom( wsDisplay,"_NET_WM_STATE_FULLSCREEN",False );
+ for ( i=0;i < nitems;i++ )
+ if ( args[i] == type ) { e.xclient.data.l[1]=XInternAtom( wsDisplay,"_NET_WM_STATE_FULLSCREEN",False ); break; }
+
e.xclient.data.l[2]=0l;
e.xclient.data.l[3]=0l;
e.xclient.data.l[4]=0l;