xwayland: exclude unfocusable views from wlr-foreign-toplevel

These views (notifications, floating toolbars, etc.) should not be
shown in taskbars/docks/etc. (which are the stated use-case of the
wlr-foreign-toplevel protocol).
This commit is contained in:
John Lindgren 2024-03-17 16:16:24 -04:00 committed by Johan Malm
parent 4fa51b950c
commit 7e419f7584

View file

@ -654,7 +654,12 @@ xwayland_view_map(struct view *view)
} }
view_maximize(view, axis, /*store_natural_geometry*/ true); view_maximize(view, axis, /*store_natural_geometry*/ true);
if (!view->toplevel.handle) { /*
* Exclude unfocusable views from wlr-foreign-toplevel. These
* views (notifications, floating toolbars, etc.) should not be
* shown in taskbars/docks/etc.
*/
if (!view->toplevel.handle && view_is_focusable(view)) {
init_foreign_toplevel(view); init_foreign_toplevel(view);
} }