From e0647b7fc2336c4f9e54eff6da6f7d2627232cc7 Mon Sep 17 00:00:00 2001 From: Michael Stapelberg Date: Thu, 3 Mar 2011 13:59:42 +0100 Subject: [PATCH] =?utf8?q?Bugfix:=20don=E2=80=99t=20focus=20dock=20clients?= =?utf8?q?=20(Thanks=20mseed,=20mist)?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Fixes #321 and #323 --- src/click.c | 7 +++++++ src/handlers.c | 5 +++++ 2 files changed, 12 insertions(+) diff --git a/src/click.c b/src/click.c index 8617cf0b..51472954 100644 --- a/src/click.c +++ b/src/click.c @@ -307,6 +307,13 @@ int handle_button_press(void *ignored, xcb_connection_t *conn, xcb_button_press_ } } + if ((clicked_into ? clicked_into->parent->type : con->parent->type) == CT_DOCKAREA) { + DLOG("Not handling, this client is inside a dockarea\n"); + xcb_allow_events(conn, XCB_ALLOW_REPLAY_POINTER, event->time); + xcb_flush(conn); + return 0; + } + /* click to focus, either on the clicked window or its child if thas was a * click into a child decoration */ con_focus((clicked_into ? clicked_into : con)); diff --git a/src/handlers.c b/src/handlers.c index 23e9c17a..35d8367a 100644 --- a/src/handlers.c +++ b/src/handlers.c @@ -181,6 +181,11 @@ int handle_enter_notify(void *ignored, xcb_connection_t *conn, return 1; } + if (con->parent->type == CT_DOCKAREA) { + DLOG("Ignoring, this is a dock client\n"); + return 1; + } + /* see if the user entered the window on a certain window decoration */ int layout = (enter_child ? con->parent->layout : con->layout); Con *child; -- 2.39.5