Skip to content

gdk/wayland: Properly calculate coordinates for show_window_menu()

Robert Mader requested to merge rmader/gtk:wayland_window_menu into gtk-3-24

The event received in gdk_wayland_window_show_window_menu() can come from widgets with a GdkWindow. In those cases the coordinates are relative to the widget, not the root window. This results in a misplaced window menu.

Properly calculate the coordinates by iterating to the toplevel window as suggested by Carlos Garnacho.

Fixes #1781 (closed)

Edited by Robert Mader

Merge request reports