Bug 420460

Summary: Global shortcut for 'Minimize All' doesn't work well with the respective applet
Product: [Plasma] plasmashell Reporter: Andrey Kozlovskiy <akozlovskiy119>
Component: Show Desktop/Minimize All widgetsAssignee: Plasma Bugs List <plasma-bugs-null>
Status: CONFIRMED ---    
Severity: normal CC: nate, twinshadows404
Priority: NOR Keywords: usability
Version First Reported In: master   
Target Milestone: 1.0   
Platform: Neon   
OS: Linux   
See Also: https://bugs.kde.org/show_bug.cgi?id=368281
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: 'Minimize All' test, shortcut - applet click
'Show Desktop' test, shortcut - applet click: works ok
video

Description Andrey Kozlovskiy 2020-04-23 13:42:01 UTC
Created attachment 127795 [details]
'Minimize All' test, shortcut - applet click

If you first use global shortcut to minimize all windows (Meta+Shift+D) and then click on the respective applet (or vice versa: click first, shortcut next), nothing happens. I believe it should restore windows to their original non-minimized state.

If you do the same thing but with 'Show Desktop' it works well, applet and global shortcut (Meta+D) can both be used interchangeably to show/hide windows.

STEPS TO REPRODUCE
1. Enable 'Minimize All' global shortcut with KWin script (Settings -> Window Management -> KWin Scripts -> Minimize All)
2. Use the shortcut to minimize all windows
3. Click on the respective 'Minimize All Windows' panel applet to restore windows
4. Nothing happens

EXPECTED RESULT
Click on applet after using shortcut (or vice versa) should restore windows to their original state.
Comment 1 Andrey Kozlovskiy 2020-04-23 13:42:52 UTC
Created attachment 127796 [details]
'Show Desktop' test, shortcut - applet click: works ok
Comment 2 Andrey Kozlovskiy 2020-04-23 13:44:19 UTC
Off topic:

In general, there exist 8 cases of shortcut and applet click combinations that should be tested for intuitive and correct work:
1. 'Minimize All' shortcut -> 'Minimize All' applet
2. 'Minimize All' shortcut -> 'Show Desktop' applet
3. 'Minimize All' applet   -> 'Minimize All' shortcut
4. 'Minimize All' applet   -> 'Show Desktop' shortcut
5. 'Show Desktop' shortcut -> 'Minimize All' applet
6. 'Show Desktop' shortcut -> 'Show Desktop' applet
7. 'Show Desktop' applet   -> 'Minimize All' shortcut
8. 'Show Desktop' applet   -> 'Show Desktop' shortcut

I personally think cases 2, 4, 6 and 8 work pretty intuitive, 1 and 3 work wrong (as explained above), 5 and 7 work strange (windows are still visible on the corners after minimization, idk if this is intended).
Comment 3 Andrey Kozlovskiy 2020-04-23 14:02:02 UTC
Non trivial shortcut - shortcut and applet - applet cases should be considered too.
Comment 4 twinshadows404 2020-12-10 13:23:36 UTC
Created attachment 133965 [details]
video

(In reply to Andrey Kozlovskiy from comment #2)

> (windows are still visible on the corners after minimization, idk if this is intended).

It's intended. I also found another bug where using the show desktop makes firefox flicker. IMO the show desktop should simply be removed and clicking on it should minimize all windows..