diff --git a/src/scriptengines/qml/plasmoid/containmentinterface.cpp b/src/scriptengines/qml/plasmoid/containmentinterface.cpp index f16800282..3a24b3aa7 100644 --- a/src/scriptengines/qml/plasmoid/containmentinterface.cpp +++ b/src/scriptengines/qml/plasmoid/containmentinterface.cpp @@ -966,6 +966,12 @@ void ContainmentInterface::mousePressEvent(QMouseEvent *event) } } + if (desktopMenu->isEmpty()) { + delete desktopMenu; + event->accept(); + return; + } + desktopMenu->popup(pos); event->setAccepted(true); }