mirror of
https://github.com/swaywm/sway.git
synced 2026-04-17 06:46:32 -04:00
container: Move foreign toplevel enter/leave events to view
It made sense to put it on the container level because the protocol cares about the toplevel and that includes its decorations. But, this breaks down when we consider if the container's view is fullscreen and the container decorations are disabled. Moving it to the view manages this expected lifetime better. Since the buffer is now part of the view, the buffer will get negative coordinates to act as if it's part of the container when we want to. A known issue is that we will send spurious leave/enter events while we reconfigure the scene for entering/exiting fullscreen. The fix for this loops back to atomic updates to scene and that is outside of the scope of this commit. Fixes: #9000
This commit is contained in:
parent
1606311553
commit
81246fc6dc
5 changed files with 66 additions and 76 deletions
|
|
@ -91,10 +91,6 @@ struct sway_container {
|
|||
} border;
|
||||
|
||||
struct wlr_scene_tree *content_tree;
|
||||
struct wlr_scene_buffer *output_handler;
|
||||
|
||||
struct wl_listener outputs_update;
|
||||
struct wl_listener output_handler_destroy;
|
||||
|
||||
struct sway_container_state current;
|
||||
struct sway_container_state pending;
|
||||
|
|
|
|||
|
|
@ -69,6 +69,9 @@ struct sway_view {
|
|||
struct wlr_scene_tree *scene_tree;
|
||||
struct wlr_scene_tree *content_tree;
|
||||
struct wlr_scene_tree *saved_surface_tree;
|
||||
struct wlr_scene_buffer *output_handler;
|
||||
|
||||
struct wl_listener outputs_update;
|
||||
|
||||
struct wlr_scene *image_capture_scene;
|
||||
struct wlr_ext_image_capture_source_v1 *image_capture_source;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue