
The main monitor is role dependent. For a toplevel this comes from the MetaWindow main monitor, for a subsurface from the parent surface, for pointer and dnd from the cursor position. The next commit will use meta_wayland_surface_set_main_monitor in the different roles to keep the property up-to-date. Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3941>