kiosk-shell: Don't occlude shsurf on other outputs

This adds an additional check to make sure the current focus surface
is on the same output as the surface that is going to be activated.

This is necessary in order to avoid placing the currently focused one in
the inactive layer, which shouldn't happen in situations where the new
surface is going to be placed on a different output than the currently
focused one.

Signed-off-by: Marius Vlad <marius.vlad@collabora.com>
(cherry picked from commit f3ad593925)
dev
Marius Vlad 3 years ago
parent c8d638b35a
commit 52c924ad7e
  1. 6
      kiosk-shell/kiosk-shell.c

@ -390,8 +390,10 @@ kiosk_shell_surface_activate(struct kiosk_shell_surface *shsurf,
/* removes it from the normal_layer and move it to inactive /* removes it from the normal_layer and move it to inactive
* one, without occluding the top-level window if the new one * one, without occluding the top-level window if the new one
* is a child to that */ * is a child to that. Also, do not occlude another view
if (!shsurf->parent) { * (currently focused one) on a different output when activating
* a new one. */
if (!shsurf->parent && (shsurf->output == current_focus->output)) {
weston_layer_entry_remove(&current_focus->view->layer_link); weston_layer_entry_remove(&current_focus->view->layer_link);
weston_layer_entry_insert(&shsurf->shell->inactive_layer.view_list, weston_layer_entry_insert(&shsurf->shell->inactive_layer.view_list,
&current_focus->view->layer_link); &current_focus->view->layer_link);

Loading…
Cancel
Save