aboutsummaryrefslogtreecommitdiffstats
path: root/include/sway/tree/container.h
diff options
context:
space:
mode:
authorLibravatar Ryan Dwyer <ryandwyer1@gmail.com>2018-06-23 16:24:11 +1000
committerLibravatar Ryan Dwyer <ryandwyer1@gmail.com>2018-06-23 16:24:11 +1000
commit38398e2d77d57dc06b67ec88a54091c897915602 (patch)
treec80935807865fd96ab7d037070287d4dfaba1863 /include/sway/tree/container.h
parentPreserve buffers during transactions (diff)
downloadsway-38398e2d77d57dc06b67ec88a54091c897915602.tar.gz
sway-38398e2d77d57dc06b67ec88a54091c897915602.tar.zst
sway-38398e2d77d57dc06b67ec88a54091c897915602.zip
Implement atomic layout updates for tree operations
This implements atomic layout updates for when views map, reparent or unmap.
Diffstat (limited to 'include/sway/tree/container.h')
-rw-r--r--include/sway/tree/container.h16
1 files changed, 12 insertions, 4 deletions
diff --git a/include/sway/tree/container.h b/include/sway/tree/container.h
index f4e978ea..7e78cbef 100644
--- a/include/sway/tree/container.h
+++ b/include/sway/tree/container.h
@@ -65,8 +65,8 @@ struct sway_container_state {
65 double gaps_inner; 65 double gaps_inner;
66 double gaps_outer; 66 double gaps_outer;
67 67
68 //struct sway_container *parent; 68 struct sway_container *parent;
69 //list_t *children; 69 list_t *children;
70 70
71 // View properties 71 // View properties
72 double view_x, view_y; 72 double view_x, view_y;
@@ -79,6 +79,10 @@ struct sway_container_state {
79 bool border_bottom; 79 bool border_bottom;
80 bool border_left; 80 bool border_left;
81 bool border_right; 81 bool border_right;
82
83 // Workspace properties
84 struct sway_view *ws_fullscreen;
85 struct sway_container *ws_floating;
82}; 86};
83 87
84struct sway_container { 88struct sway_container {
@@ -128,8 +132,6 @@ struct sway_container {
128 132
129 struct sway_container *parent; 133 struct sway_container *parent;
130 134
131 list_t *marks; // list of char*
132
133 float alpha; 135 float alpha;
134 136
135 struct wlr_texture *title_focused; 137 struct wlr_texture *title_focused;
@@ -138,6 +140,10 @@ struct sway_container {
138 struct wlr_texture *title_urgent; 140 struct wlr_texture *title_urgent;
139 size_t title_height; 141 size_t title_height;
140 142
143 list_t *instructions; // struct sway_transaction_instruction *
144
145 bool destroying;
146
141 struct { 147 struct {
142 struct wl_signal destroy; 148 struct wl_signal destroy;
143 // Raised after the tree updates, but before arrange_windows 149 // Raised after the tree updates, but before arrange_windows
@@ -181,6 +187,8 @@ struct sway_container *workspace_create(struct sway_container *output,
181struct sway_container *container_view_create( 187struct sway_container *container_view_create(
182 struct sway_container *sibling, struct sway_view *sway_view); 188 struct sway_container *sibling, struct sway_view *sway_view);
183 189
190void container_free(struct sway_container *cont);
191
184struct sway_container *container_destroy(struct sway_container *container); 192struct sway_container *container_destroy(struct sway_container *container);
185 193
186struct sway_container *container_close(struct sway_container *container); 194struct sway_container *container_close(struct sway_container *container);