Merge pull request #509 from psychon/systray_substructure_redirect

Select SubstructureRedirect on our systray window
This commit is contained in:
Daniel Hahler 2015-10-13 11:34:12 +02:00
commit 75aea6086d
2 changed files with 8 additions and 2 deletions

View file

@ -373,6 +373,12 @@ event_handle_configurerequest(xcb_configure_request_event_t *ev)
/* ICCCM 4.1.5 / 4.2.3, if nothing was changed, send an event saying so */
client_send_configure(c);
}
else if (xembed_getbywin(&globalconf.embedded, ev->window))
{
/* Ignore this so that systray icons cannot resize themselves.
* We decide their size!
*/
}
else
event_handle_configurerequest_configure_window(ev);
}

View file

@ -48,8 +48,8 @@ systray_init(void)
xscreen->root,
-1, -1, 1, 1, 0,
XCB_COPY_FROM_PARENT, xscreen->root_visual,
XCB_CW_BACK_PIXEL, (const uint32_t [])
{ xscreen->black_pixel });
XCB_CW_BACK_PIXEL | XCB_CW_EVENT_MASK, (const uint32_t [])
{ xscreen->black_pixel, XCB_EVENT_MASK_SUBSTRUCTURE_REDIRECT });
atom_name = xcb_atom_name_by_screen("_NET_SYSTEM_TRAY", globalconf.default_screen);
if(!atom_name)