From ed8b581dda890ad999380a9c8e3095950786c133 Mon Sep 17 00:00:00 2001 From: Kai Uwe Broulik Date: Wed, 9 Aug 2023 17:03:50 +0200 Subject: [PATCH] XdgTopLevelWindow: Translate window menu coordinate from local The show_window_menu request is in surface-local coordinates, which include any client-side window shadows. Translate the menu coordinates so the window shows up in the right spot. --- src/xdgshellwindow.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/xdgshellwindow.cpp b/src/xdgshellwindow.cpp index e6c0341983..16bf18593a 100644 --- a/src/xdgshellwindow.cpp +++ b/src/xdgshellwindow.cpp @@ -925,7 +925,7 @@ void XdgToplevelWindow::handleWindowClassChanged() void XdgToplevelWindow::handleWindowMenuRequested(SeatInterface *seat, const QPoint &surfacePos, quint32 serial) { - performMouseCommand(Options::MouseOperationsMenu, pos() + surfacePos); + performMouseCommand(Options::MouseOperationsMenu, mapFromLocal(surfacePos)); } void XdgToplevelWindow::handleMoveRequested(SeatInterface *seat, quint32 serial)