diff --git a/useractions.cpp b/useractions.cpp --- a/useractions.cpp +++ b/useractions.cpp @@ -152,18 +152,15 @@ int x = pos.left(); int y = pos.bottom(); const bool needsPopup = kwinApp()->shouldUseWaylandForCompositing(); + m_client->blockActivityUpdates(true); + if (y == pos.top()) { - m_client->blockActivityUpdates(true); if (needsPopup) { m_menu->popup(QPoint(x, y)); } else { m_menu->exec(QPoint(x, y)); } - if (m_client) { - m_client->blockActivityUpdates(false); - } } else { - m_client->blockActivityUpdates(true); QRect area = ws->clientArea(ScreenArea, QPoint(x, y), VirtualDesktopManager::self()->current()); menuAboutToShow(); // needed for sizeHint() to be correct :-/ int popupHeight = m_menu->sizeHint().height(); @@ -180,9 +177,9 @@ m_menu->exec(QPoint(x, pos.top() - popupHeight)); } } - if (m_client) { - m_client->blockActivityUpdates(false); - } + } + if (m_client) { + m_client->blockActivityUpdates(false); } }