From 3f0b4826dd06551ee066d9e94f36d83d8a801cf6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20L=C3=BCbking?= Date: Tue, 21 Feb 2012 23:55:55 +0100 Subject: [PATCH 1/3] - lower windows does not change focus for F(S)UM - lower by shortcut honors nextFocusPrefersMouse setting CCBUG: 80897 REVIEW: 104041 --- useractions.cpp | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/useractions.cpp b/useractions.cpp index 5b74e2e2c5..7614c72608 100644 --- a/useractions.cpp +++ b/useractions.cpp @@ -820,7 +820,7 @@ bool Client::performMouseCommand(Options::MouseCommand command, const QPoint &gl workspace()->lowerClient(this); // used to be activateNextClient(this), then topClientOnDesktop // since this is a mouseOp it's however safe to use the client under the mouse instead - if (isActive()) { + if (isActive() && options->focusPolicyIsReasonable()) { Client *next = workspace()->clientUnderMouse(screen()); if (next && next != this) workspace()->requestFocus(next, false); @@ -1239,8 +1239,15 @@ void Workspace::slotWindowLower() // As this most likely makes the window no longer visible change the // keyboard focus to the next available window. //activateNextClient( c ); // Doesn't work when we lower a child window - if (active_client->isActive()) - activateClient(topClientOnDesktop(currentDesktop(), -1)); + if (active_client->isActive() && options->focusPolicyIsReasonable()) { + if (options->nextFocusPrefersMouse) { + Client *next = clientUnderMouse(active_client->screen()); + if (next && next != active_client) + requestFocus(next, false); + } else { + activateClient(topClientOnDesktop(currentDesktop(), -1)); + } + } } } From c885d88f28d8016dccccbaa82ed6cb60e543b560 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20L=C3=BCbking?= Date: Wed, 29 Feb 2012 01:17:42 +0100 Subject: [PATCH 2/3] set desktop w/o desktop hint on all desktops helps with legacy desktops replacing decorations like IceWM which withdraw the desktop settings REVIEW: 104112 --- manage.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/manage.cpp b/manage.cpp index adbe29c281..837d65efed 100644 --- a/manage.cpp +++ b/manage.cpp @@ -220,7 +220,7 @@ bool Client::manage(Window w, bool isMapped) } } if (desk == 0) // Assume window wants to be visible on the current desktop - desk = workspace()->currentDesktop(); + desk = isDesktop() ? NET::OnAllDesktops : workspace()->currentDesktop(); desk = rules()->checkDesktop(desk, !isMapped); if (desk != NET::OnAllDesktops) // Do range check desk = qMax(1, qMin(workspace()->numberOfDesktops(), desk)); From 3e4cb7539e6712f8e43df5c078a24c73c625a7d5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thomas=20L=C3=BCbking?= Date: Sun, 4 Mar 2012 07:48:28 +0100 Subject: [PATCH 3/3] fix shading for xrender compositing REVIEW: 104150 --- scene_xrender.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scene_xrender.cpp b/scene_xrender.cpp index e7dd355660..b2a11c863e 100644 --- a/scene_xrender.cpp +++ b/scene_xrender.cpp @@ -724,7 +724,7 @@ XRenderComposite(display(), PictOpOver, m_xrenderShadow->shadowPixmap(SceneXRend } #undef RENDER_SHADOW_TILE - if (!(mask & PAINT_DECORATION_ONLY)) { + if (!((mask & PAINT_DECORATION_ONLY) || (client && client->isShade()))) { // Paint the window contents Picture clientAlpha = opaque ? None : alphaMask(data.opacity); XRenderComposite(display(), clientRenderOp, pic, clientAlpha, renderTarget, cr.x(), cr.y(), 0, 0, dr.x(), dr.y(), dr.width(), dr.height());