Bug 373153

Summary: Closing windows with sorting "By activity" leads to mixed-up taskbar
Product: [Plasma] plasmashell Reporter: Ralf Jung <post>
Component: Task Manager and Icons-Only Task ManagerAssignee: Eike Hein <hein>
Status: RESOLVED DUPLICATE    
Severity: normal CC: nate, plasma-bugs
Priority: NOR    
Version: 5.8.2   
Target Milestone: 1.0   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Attachments: A screenshot demonstrating the issue
Screenshot of my task manager settings

Description Ralf Jung 2016-12-01 18:34:17 UTC
Created attachment 102563 [details]
A screenshot demonstrating the issue

Steps to reproduce:

* Have at least 3 windows in a group.
* Left-click that group
* Right-click a window in that group and select "Close"

Expected behavior:

* The window closed and disappears from the group, and nothing else happens

Actual behavior:

* Another window can start showing up in the group -- even windows that are not usually shown, e.g. "plasma".  I will attach a screenshot demonstrating this.

This is not entirely reproducible because it seems to depend on the exact state of the task manager, i.e. how many groups of which size are presented in which order. Still, it happens frequently for me.  Having more windows grouped increases the likelihood of seeing this.
Comment 1 Ralf Jung 2016-12-02 14:22:39 UTC
Actually I now frequently get a slightly messed-up task manager even when no windows are grouped.  For example, I just used right-click "Close" to close one of two qgit windows I had open (grouping was disabled). Then *both* vanished from the taskbar, and some icons of other windows got swapped. Switching the active window repaired the taskbar, i.e., the missing qgit window came back and the icons all got fixed.
Comment 2 Eike Hein 2016-12-06 14:56:13 UTC
Please attach a screenshot of your Task Manager config dialog.
Comment 3 Ralf Jung 2016-12-07 09:40:50 UTC
Created attachment 102657 [details]
Screenshot of my task manager settings

These are the settings I use most of the time -- even when there are no groups, I occasionally get screwed-up windows in the taskbar.

For the original report (closing a window from a group), the settings were the same except that "Grouping" was set to "By Program Name".
Comment 4 Eike Hein 2016-12-07 11:33:51 UTC
The "By Activity" sorting strikes me as the outlier there (it's rarely used).
Comment 5 Ralf Jung 2016-12-07 12:38:34 UTC
I don't actually use activities, so this is probably something I changed years ago...

However, after disabling this (and enabling the grouping again), I was able to still reproduce the issue on the first try.
Comment 6 Ralf Jung 2016-12-13 11:44:18 UTC
*oops* I am sorry I misread what you wrote... I read "setting" instead of "sorting", so I was changing the option "Show only tasks of current activity".

Indeed changing the sorting to "Alphabetically" fixes the problem.  I have no idea why the sorting option is what it was.  I now set it to "By Desktop" and will see how that one behaves.  So far, it did not leave things in a bad state; however, the animations when closing a window do look a bit odd -- instead of the closed window being animated to disappear, some other window disappears and then there is a smooth transition if taskbar entires changing their icon and text. That doesn't look right.
Comment 7 Nate Graham 2017-12-13 23:50:28 UTC
Same issue or likely root cause as Bug 369576.

*** This bug has been marked as a duplicate of bug 369576 ***