Commit 49fdd73e authored by Vlad Zahorodnii's avatar Vlad Zahorodnii

[kstyle] Properly unregister widgets in ShadowHelper

After a widget has been unregistered, a WinIdChange event may be sent.
If that happens, ShadowHelper is going to try to install a shadow for
the corresponding widget. Obviously, this is wrong.

Reviewers: #plasma, cblack

Reviewed By: cblack

Subscribers: plasma-devel

Tags: #plasma

Differential Revision:
parent 600b9030
......@@ -142,7 +142,16 @@ namespace Breeze
void ShadowHelper::unregisterWidget( QWidget* widget )
if( _widgets.remove( widget ) )
{ uninstallShadows( widget ); }
// uninstall the event filter
widget->removeEventFilter( this );
// disconnect all signals
disconnect( widget, nullptr, this, nullptr );
// uninstall the shadow
uninstallShadows( widget );
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment