summaryrefslogtreecommitdiffstats
path: root/Gui/wm
diff options
context:
space:
mode:
authorpontscho <pontscho@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-11-11 16:57:09 +0000
committerpontscho <pontscho@b3059339-0415-0410-9bf9-f77b7e298cf2>2002-11-11 16:57:09 +0000
commitffc3a5801196e732e1f715719f80f5bd9fa72dac (patch)
treea7b40efb6a839a0a4fe1b4d6037d2309a2f1e5be /Gui/wm
parent2dc3b7951cc51e29b03ad1e9c9918ff9e9ef2f93 (diff)
downloadmpv-ffc3a5801196e732e1f715719f80f5bd9fa72dac.tar.bz2
mpv-ffc3a5801196e732e1f715719f80f5bd9fa72dac.tar.xz
updating
git-svn-id: svn://svn.mplayerhq.hu/mplayer/trunk@8151 b3059339-0415-0410-9bf9-f77b7e298cf2
Diffstat (limited to 'Gui/wm')
-rw-r--r--Gui/wm/ws.c47
1 files changed, 24 insertions, 23 deletions
diff --git a/Gui/wm/ws.c b/Gui/wm/ws.c
index ba4b21e708..4d1c2b9baf 100644
--- a/Gui/wm/ws.c
+++ b/Gui/wm/ws.c
@@ -770,7 +770,7 @@ while(wsTrue){
#define WIN_LAYER_ONBOTTOM 2
#define WIN_LAYER_NORMAL 4
-#define WIN_LAYER_ONTOP 6
+#define WIN_LAYER_ONTOP 10
void wsSetLayer( Display * wsDisplay, Window win, int layer )
{
@@ -791,6 +791,29 @@ void wsSetLayer( Display * wsDisplay, Window win, int layer )
XInternAtom( wsDisplay,"_WIN_LAYER",False ),XA_CARDINAL,32,PropModeReplace,(unsigned char *)&layer,1 );
return;
}
+
+ type=XInternAtom( wsDisplay,"_WIN_SUPPORTING_WM_CHECK",False );
+ if ( Success == XGetWindowProperty( wsDisplay,wsRootWin,type,0,65536 / sizeof( int32_t ),False,AnyPropertyType,&type,&format,&nitems,&bytesafter,(unsigned char **)&args ) && nitems > 0 )
+ {
+ XClientMessageEvent xev;
+
+ memset( &xev,0,sizeof( xev ) );
+ xev.type=ClientMessage;
+ xev.window=win;
+ xev.message_type=XInternAtom( wsDisplay,"_WIN_LAYER",False );
+ xev.format=32;
+ switch ( layer )
+ {
+ case -1: xev.data.l[0] = WIN_LAYER_ONBOTTOM; break;
+ case 0: xev.data.l[0] = WIN_LAYER_NORMAL; break;
+ case 1: xev.data.l[0] = WIN_LAYER_ONTOP; break;
+ }
+ XSendEvent( wsDisplay,wsRootWin,False,SubstructureNotifyMask,(XEvent*)&xev );
+ if ( layer ) XRaiseWindow( wsDisplay,win );
+
+ XFree( args );
+ return;
+ }
type=XInternAtom( wsDisplay,"_NET_SUPPORTED",False );
if ( Success == XGetWindowProperty( wsDisplay,wsRootWin,type,0,65536 / sizeof( int32_t ),False,AnyPropertyType,&type,&format,&nitems,&bytesafter,(unsigned char **)&args ) && nitems > 0 )
@@ -818,28 +841,6 @@ void wsSetLayer( Display * wsDisplay, Window win, int layer )
XFree( args );
return;
}
- type=XInternAtom( wsDisplay,"_WIN_SUPPORTING_WM_CHECK",False );
- if ( Success == XGetWindowProperty( wsDisplay,wsRootWin,type,0,65536 / sizeof( int32_t ),False,AnyPropertyType,&type,&format,&nitems,&bytesafter,(unsigned char **)&args ) && nitems > 0 )
- {
- XClientMessageEvent xev;
-
- memset( &xev,0,sizeof( xev ) );
- xev.type=ClientMessage;
- xev.window=win;
- xev.message_type=XInternAtom( wsDisplay,"_WIN_LAYER",False );
- xev.format=32;
- switch ( layer )
- {
- case -1: xev.data.l[0] = WIN_LAYER_ONBOTTOM; break;
- case 0: xev.data.l[0] = WIN_LAYER_NORMAL; break;
- case 1: xev.data.l[0] = WIN_LAYER_ONTOP; break;
- }
- XSendEvent( wsDisplay,wsRootWin,False,SubstructureNotifyMask,(XEvent*)&xev );
- if ( layer ) XRaiseWindow( wsDisplay,win );
-
- XFree( args );
- return;
- }
}
// ----------------------------------------------------------------------------------------------