Bug 470812

Summary: Deleting a widget doesn't close its popup if it happened to be open at the moment it was deleted
Product: [Plasma] plasmashell Reporter: esperluette08
Component: generalAssignee: Plasma Bugs List <plasma-bugs-null>
Status: CONFIRMED ---    
Severity: minor CC: filip.kendes1, joshuaholzhauser, kde, nate, notmart
Priority: LO    
Version First Reported In: 5.27.5   
Target Milestone: 1.0   
Platform: Neon   
OS: Linux   
Latest Commit: Version Fixed/Implemented In:
Sentry Crash Report:
Attachments: Application launcher still visible even the widget has been deleted (confirmed by the notification)

Description esperluette08 2023-06-08 23:19:13 UTC
Created attachment 159551 [details]
Application launcher still visible even the widget has been deleted (confirmed by the notification)

SUMMARY
Deleting an Application Launcher/Menu, when clicking then right-clicking fast (during the opening animation of the menu/launcher, I guess) doesn't close the launcher/menu.

Tested on a (slow) VM, it may be more difficult to reproduce on a fast computer.

STEPS TO REPRODUCE
1. Adding Application Launcher or/and Application Menu to desktop
2. Click on the widget then immediately right-click to show the menu
3. Select "Delete Application Launcher/Menu" to delete the widget (with the menu/launcher still visible)

OBSERVED RESULT
The widget is deleted, a notification confirms it, but the launcher/menu is still visible (see screenshot).

It's a minor bug since clicking anywhere outside the menu/launcher close it.

EXPECTED RESULT
The widget should close the menu/launcher once deleted (or maybe even on right-click, cancelling the opening).

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: Neon Live (20230504-0714)
KDE Plasma Version: 5.27.5
KDE Frameworks Version: 5.106.0
Qt Version: 5.15.9
Graphics: X11
Comment 1 Nate Graham 2023-06-09 19:28:11 UTC
Technically the applet isn't deleted internally until you close the notification, so that's why it's still able to appear after being deleted. If you close the notification when it's in this state, the popup will disappear.

We already handle this circumstance by blocking a widget's ability to be activated by keyboard shortcuts after it's been deleted; I guess we should also make sure to close it if it happens to be open when deleted.
Comment 2 Nate Graham 2024-11-13 18:25:03 UTC
*** Bug 496138 has been marked as a duplicate of this bug. ***
Comment 3 Niccolò Venerandi 2025-10-26 16:11:25 UTC
*** Bug 504980 has been marked as a duplicate of this bug. ***