1
0
mirror of https://github.com/Llewellynvdm/conky.git synced 2024-11-18 02:55:12 +00:00

forward ButtonRelease too

git-svn-id: https://conky.svn.sourceforge.net/svnroot/conky/trunk/conky@569 7f574dfc-610e-0410-a909-a81674777703
This commit is contained in:
Philip Kovacs 2006-03-08 23:02:28 +00:00
parent b93a28ee61
commit 49c9b8d6d5
2 changed files with 13 additions and 2 deletions

View File

@ -4581,6 +4581,16 @@ static void main_loop()
XSendEvent(display, ev.xbutton.window, False, ButtonPressMask, &ev);
}
break;
case ButtonRelease:
if (own_window)
{
/* forward the release to the desktop window */
ev.xbutton.window = window.desktop;
XSendEvent(display, ev.xbutton.window, False, ButtonReleaseMask, &ev);
}
break;
#endif
default:

View File

@ -208,7 +208,7 @@ void init_window(int own_window, int w, int h, int set_trans, int back_colour, c
* events are now explicitly forwarded to the desktop window. */
XSetWindowAttributes attrs = {
ParentRelative,0L,0,0L,0,0,Always,0L,0L,False,
StructureNotifyMask|ExposureMask|ButtonPressMask,
StructureNotifyMask|ExposureMask|ButtonPressMask|ButtonReleaseMask,
0L,False,0,0 };
XClassHint classHint;
@ -454,7 +454,8 @@ void init_window(int own_window, int w, int h, int set_trans, int back_colour, c
XSelectInput(display, window.window, ExposureMask
#ifdef OWN_WINDOW
| (own_window
? (StructureNotifyMask | PropertyChangeMask | ButtonPressMask) : 0)
? (StructureNotifyMask | PropertyChangeMask |
ButtonPressMask | ButtonReleaseMask) : 0)
#endif
);
}