Bug 470707

Summary: Rare sequence of clicks causes following clicks on icon to have no effect
Product: [Plasma] plasmashell Reporter: php4fan
Component: Task Manager and Icons-Only Task Manager widgetsAssignee: Plasma Bugs List <plasma-bugs-null>
Status: RESOLVED FIXED    
Severity: minor CC: nate
Priority: NOR    
Version First Reported In: 5.27.4   
Target Milestone: 1.0   
Platform: Manjaro   
OS: Linux   
Latest Commit: Version Fixed/Implemented In: 6.0
Sentry Crash Report:

Description php4fan 2023-06-06 17:18:38 UTC
SUMMARY
***
NOTE: If you are reporting a crash, please try to attach a backtrace with debug symbols.
See https://community.kde.org/Guidelines_and_HOWTOs/Debugging/How_to_create_useful_crash_reports
***


STEPS TO REPRODUCE
1. Choose any two applications A and B that are both open and have their corresponding icons in the task manager. For example, A = Thunderbird and B = Kate. Give focus to application B and maximize it
2. Move the mouse cursor over application A's icon and do the following sequence of clicks:
3. press and hold the LEFT mouse button
4. press and hold the RIGHT mouse button
5. release only the LEFT button and press it again, holding it
6. release the RIGHT button, then the LEFT one (or the other way around, it makes no difference)
7. now click again on application's A icon, with a normal single click.
8. Repeat step 7 any number of times

OBSERVED RESULT
at step 7 and 8, nothing happens. Application B is still the focused one, and clicking on A's icon doesn't give focus to A.
In order to be able to give focus to A, I need to first switch focus to some other application C (or click on B's icon), and only then clicking on A's icon works.


EXPECTED RESULT
Regardless of what happens during steps 3-6, definitely at step 7 and 8 clicking on A's icon should give focus to A. A is not the currently focused application, and I'm clicking on its icon. Nothing else (that I can think of) is relevant: this should give focus to A.


SOFTWARE/OS VERSIONS
Operating System: Manjaro Linux 
KDE Plasma Version: 5.27.4
KDE Frameworks Version: 5.105.0
Qt Version: 5.15.9
Kernel Version: 6.1.26-1-MANJARO (64-bit)
Graphics Platform: X11
Processors: 8 × Intel® Core™ i7-1065G7 CPU @ 1.30GHz
Memory: 7.3 GiB of RAM
Graphics Processor: Mesa Intel® Iris® Plus Graphics
Manufacturer: LENOVO
Product Name: 81WE
System Version: IdeaPad 3 15IIL05
Comment 1 Nate Graham 2023-06-07 17:54:11 UTC
Hah, thanks for the extremely detailed steps to reproduce. Cannot reproduce on Plasma 6. I do recall some weird click-related things reported in the past that remind me of this, and those got fixed, so let's call it fixed in Plasma 6.