diff options
| author | Daniel Eklöf <daniel@ekloef.se> | 2021-01-10 14:40:11 +0000 |
|---|---|---|
| committer | Daniel Eklöf <daniel@ekloef.se> | 2021-01-26 18:32:06 +0000 |
| commit | 4ebd58e38888939d221d5616debc2e72dcfb4516 (patch) | |
| tree | 47ae5558d31b3c5e08a93b1ae79054e48a6d397d | |
| parent | wayland: pack booleans in the “pending” configure struct (diff) | |
wayland: track is-resizing state
| -rw-r--r-- | wayland.c | 9 | ||||
| -rw-r--r-- | wayland.h | 2 |
2 files changed, 6 insertions, 5 deletions
@@ -535,6 +535,7 @@ xdg_toplevel_configure(void *data, struct xdg_toplevel *xdg_toplevel, bool is_activated = false; bool is_fullscreen = false; bool is_maximized = false; + bool is_resizing = false; bool is_tiled_top = false; bool is_tiled_bottom = false; bool is_tiled_left = false; @@ -566,11 +567,7 @@ xdg_toplevel_configure(void *data, struct xdg_toplevel *xdg_toplevel, case XDG_TOPLEVEL_STATE_TILED_RIGHT: is_tiled_right = true; break; case XDG_TOPLEVEL_STATE_TILED_TOP: is_tiled_top = true; break; case XDG_TOPLEVEL_STATE_TILED_BOTTOM: is_tiled_bottom = true; break; - - case XDG_TOPLEVEL_STATE_RESIZING: - /* Ignored */ - /* TODO: throttle? */ - break; + case XDG_TOPLEVEL_STATE_RESIZING: is_resizing = true; break; } #if defined(LOG_ENABLE_DBG) && LOG_ENABLE_DBG @@ -614,6 +611,7 @@ xdg_toplevel_configure(void *data, struct xdg_toplevel *xdg_toplevel, win->configure.is_activated = is_activated; win->configure.is_fullscreen = is_fullscreen; win->configure.is_maximized = is_maximized; + win->configure.is_resizing = is_resizing; win->configure.is_tiled_top = is_tiled_top; win->configure.is_tiled_bottom = is_tiled_bottom; win->configure.is_tiled_left = is_tiled_left; @@ -648,6 +646,7 @@ xdg_surface_configure(void *data, struct xdg_surface *xdg_surface, bool wasnt_configured = !win->is_configured; win->is_configured = true; win->is_maximized = win->configure.is_maximized; + win->is_resizing = win->configure.is_resizing; win->is_tiled_top = win->configure.is_tiled_top; win->is_tiled_bottom = win->configure.is_tiled_bottom; win->is_tiled_left = win->configure.is_tiled_left; @@ -372,6 +372,7 @@ struct wl_window { bool is_configured; bool is_fullscreen; bool is_maximized; + bool is_resizing; bool is_tiled_top; bool is_tiled_bottom; bool is_tiled_left; @@ -383,6 +384,7 @@ struct wl_window { uint8_t is_activated:1; uint8_t is_fullscreen:1; uint8_t is_maximized:1; + uint8_t is_resizing:1; uint8_t is_tiled_top:1; uint8_t is_tiled_bottom:1; uint8_t is_tiled_left:1; |
