Commit 15dd4e11 authored by Rémi Denis-Courmont's avatar Rémi Denis-Courmont

XCB: follow mouse-events variable

parent 53231d2c
......@@ -132,9 +132,13 @@ vout_window_t *GetWindow (vout_display_t *vd,
XCB_CW_EVENT_MASK, &value);
/* Try to subscribe to click events */
/* (only one X11 client can get them, so might not work) */
value |= XCB_EVENT_MASK_BUTTON_PRESS | XCB_EVENT_MASK_BUTTON_RELEASE;
xcb_change_window_attributes (conn, wnd->handle.xid,
XCB_CW_EVENT_MASK, &value);
if (var_CreateGetBool (vd, "mouse-events"))
{
value |= XCB_EVENT_MASK_BUTTON_PRESS
| XCB_EVENT_MASK_BUTTON_RELEASE;
xcb_change_window_attributes (conn, wnd->handle.xid,
XCB_CW_EVENT_MASK, &value);
}
}
/* Find the selected screen */
......
......@@ -257,7 +257,6 @@ static int Open (vlc_object_t *obj)
const uint32_t mask = XCB_CW_EVENT_MASK | XCB_CW_COLORMAP;
const uint32_t values[] = {
/* XCB_CW_EVENT_MASK */
XCB_EVENT_MASK_BUTTON_PRESS | XCB_EVENT_MASK_BUTTON_RELEASE |
XCB_EVENT_MASK_VISIBILITY_CHANGE,
/* XCB_CW_COLORMAP */
cmap,
......
......@@ -447,7 +447,6 @@ static int Open (vlc_object_t *obj)
{
const uint32_t mask =
/* XCB_CW_EVENT_MASK */
XCB_EVENT_MASK_BUTTON_PRESS | XCB_EVENT_MASK_BUTTON_RELEASE |
XCB_EVENT_MASK_VISIBILITY_CHANGE;
xcb_void_cookie_t c;
xcb_window_t window = xcb_generate_id (conn);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment