aboutsummaryrefslogtreecommitdiff
path: root/wayland.h
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2020-10-20 18:58:03 +0000
committerDaniel Eklöf <daniel@ekloef.se>2020-10-20 18:58:03 +0000
commitf928c1fa682a3dd3728b290d8fa9de79a63538ed (patch)
treea752f300bd75c5b60c519b5fe8b5b388e663484f /wayland.h
parentMerge branch 'dont-require-a-compose-file' into master (diff)
wayland: properly restore window size when being un-tiled
Bind to xdg-shell version 2 if available, as this enables us to track our window’s ‘tiled’ state in the ‘configure’ events. This in turn allows us to stash the ‘old’ window size when being tiled, to be used again when restoring the window size when un-tiled.
Diffstat (limited to 'wayland.h')
-rw-r--r--wayland.h9
1 files changed, 9 insertions, 0 deletions
diff --git a/wayland.h b/wayland.h
index 7d512ba0..70c2098a 100644
--- a/wayland.h
+++ b/wayland.h
@@ -314,10 +314,19 @@ struct wl_window {
bool is_configured;
bool is_fullscreen;
bool is_maximized;
+ bool is_tiled_top;
+ bool is_tiled_bottom;
+ bool is_tiled_left;
+ bool is_tiled_right;
+ bool is_tiled; /* At least one of is_tiled_{top,bottom,left,right} is true */
struct {
bool is_activated;
bool is_fullscreen;
bool is_maximized;
+ bool is_tiled_top;
+ bool is_tiled_bottom;
+ bool is_tiled_left;
+ bool is_tiled_right;
int width;
int height;
} configure;