Bug 364710

Summary: Desktop Grid includes the "close window widget"
Product: [Plasma] kwin Reporter: Roland Leißa <roland.leissa>
Component: effects-desktop-gridAssignee: KWin default assignee <kwin-bugs-null>
Status: RESOLVED FIXED    
Severity: normal CC: i9i7soft, jodr666, kde, oceanofsolaris, sebastian.pb31
Priority: NOR    
Version: 5.14.2   
Target Milestone: ---   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In: 5.14.3
Sentry Crash Report:
Attachments: Seems fixed here...

Description Roland Leißa 2016-06-24 14:26:52 UTC
Somehow the "close window widget" which is seen in the "Present Window" effect makes its way into the "Desktop Grid"

Reproducible: Always

Steps to Reproduce:
1. Activate "Present Windows - Current Desktop"
2. Hover over a window such you can see the "close window widget".
3. Activate "Desktop Grid"


Actual Results:  
You can see, that  each desktop includes somewhere a small window to close a window. The exact thing that the "Present Windows" effect is showing. I guess, the "Present Windows" effect doesn't remove this widget from some global window list or something.
Comment 1 Roland Leißa 2016-07-11 12:17:44 UTC
Problem still persists in kwin 5.7.0.
Comment 2 Roland Leißa 2016-10-05 13:50:38 UTC
Problem still persists in kwin 5.8.0.
Comment 3 Martin Flöser 2016-12-04 08:05:28 UTC
*** Bug 373234 has been marked as a duplicate of this bug. ***
Comment 4 Tony 2016-12-10 15:22:54 UTC
Created attachment 102721 [details]
Seems fixed here...
Comment 5 Martin Flöser 2017-01-16 20:12:17 UTC
*** Bug 375134 has been marked as a duplicate of this bug. ***
Comment 6 Stephan Burkhardt 2017-02-21 19:16:55 UTC
I also observe this problem (Plasma 5.9.2 on Arch Linux). For me, I can't see the "close window" widget until I try to drag it [0] but it still uses up space. When I do grab it, it sometimes becomes visible though. Additionally, the "Buttons to alter count of virtual desktops" also show up in the same way (invisible until grabbed) if I enable them in the settings of the "Desktop Grid" effect.

I think this bug is not too severe, but somewhat annoying since the "present window" layout becomes very weird due to the presence of so many invisible windows.

[0] This might be related to bug Bug 361371, which I also observe on my system.
Comment 7 TYY331 2018-01-21 13:49:40 UTC
Is this going to be fixed any time soon?
Comment 8 Martin Flöser 2018-01-21 20:07:39 UTC
(In reply to TYY331 from comment #7)
> Is this going to be fixed any time soon?

I don't think this has currently any priority. In fact I'm not able to reproduce which makes it hard to fix.
Comment 9 Vlad Zahorodnii 2018-10-30 20:43:55 UTC
Git commit 558b86e9f6c08fde10933b3a3c7c126ba287c408 by Vlad Zagorodniy.
Committed on 30/10/2018 at 20:39.
Pushed by vladz into branch 'Plasma/5.14'.

[effects/desktopgrid] Don't display the close button from Present Windows

Summary:
If you activate the Present Windows effect and then the Desktop Grid,
you'll be able to see the close button from PW. The reason for that is
PW doesn't destroy the close button and DG doesn't filter it out.

This patch addesses this problem by syncing DesktopGridEffect::isRelevantWithPresentWindows
with PresentWindowsEffect::isSelectableWindow.

On X11, the close button is filtered by the isSpecialWindow check. On
Wayland, the close button is filtered by the acceptsFocus check.

The proposed solution is kinda hack-ish, but on the other hand, we have
to keep those two methods in sync anyway.

In addition to the close button, notifications won't be displayed too.
FIXED-IN: 5.14.3

Test Plan:
* Activate the Present Windows effect;
* Activate the Desktop Grid effect;
* (the close button is no longer visible)

Reviewers: #kwin, graesslin

Reviewed By: #kwin, graesslin

Subscribers: kwin

Tags: #kwin

Differential Revision: https://phabricator.kde.org/D16513

M  +25   -2    effects/desktopgrid/desktopgrid.cpp

https://commits.kde.org/kwin/558b86e9f6c08fde10933b3a3c7c126ba287c408