diff options
author | Rostislav Pehlivanov <atomnuker@gmail.com> | 2018-06-27 17:53:13 +0100 |
---|---|---|
committer | Rostislav Pehlivanov <atomnuker@gmail.com> | 2018-06-30 11:10:47 +0100 |
commit | e0d0e8f840271ab12533cb16c9a7ccba237adcb3 (patch) | |
tree | a81bf679fc25f89cc09516e1920c4496b2e4c2f8 /sway/tree/view.c | |
parent | Merge pull request #2173 from emersion/fix-floating-no-frame-event (diff) | |
download | sway-e0d0e8f840271ab12533cb16c9a7ccba237adcb3.tar.gz sway-e0d0e8f840271ab12533cb16c9a7ccba237adcb3.tar.zst sway-e0d0e8f840271ab12533cb16c9a7ccba237adcb3.zip |
Revert "Don't unmaximize floating views"
This reverts commit 97672295ed50d1d6272876c4a3b6b5607cab05c6.
Diffstat (limited to 'sway/tree/view.c')
-rw-r--r-- | sway/tree/view.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/sway/tree/view.c b/sway/tree/view.c index de4ce2e6..98637c33 100644 --- a/sway/tree/view.c +++ b/sway/tree/view.c | |||
@@ -141,6 +141,9 @@ static void view_autoconfigure_floating(struct sway_view *view) { | |||
141 | view->border_top = view->border_bottom = true; | 141 | view->border_top = view->border_bottom = true; |
142 | view->border_left = view->border_right = true; | 142 | view->border_left = view->border_right = true; |
143 | 143 | ||
144 | // Don't maximize floating windows | ||
145 | view_set_tiled(view, false); | ||
146 | |||
144 | view_configure(view, lx, ly, width, height); | 147 | view_configure(view, lx, ly, width, height); |
145 | } | 148 | } |
146 | 149 | ||
@@ -248,6 +251,7 @@ void view_autoconfigure(struct sway_view *view) { | |||
248 | 251 | ||
249 | view->x = x; | 252 | view->x = x; |
250 | view->y = y; | 253 | view->y = y; |
254 | view_set_tiled(view, true); | ||
251 | view_configure(view, x, y, width, height); | 255 | view_configure(view, x, y, width, height); |
252 | } | 256 | } |
253 | 257 | ||
@@ -257,6 +261,13 @@ void view_set_activated(struct sway_view *view, bool activated) { | |||
257 | } | 261 | } |
258 | } | 262 | } |
259 | 263 | ||
264 | void view_set_tiled(struct sway_view *view, bool tiled) { | ||
265 | view->border = tiled ? config->border : B_NONE; | ||
266 | if (view->impl->set_tiled) { | ||
267 | view->impl->set_tiled(view, tiled); | ||
268 | } | ||
269 | } | ||
270 | |||
260 | // Set fullscreen, but without IPC events or arranging windows. | 271 | // Set fullscreen, but without IPC events or arranging windows. |
261 | void view_set_fullscreen_raw(struct sway_view *view, bool fullscreen) { | 272 | void view_set_fullscreen_raw(struct sway_view *view, bool fullscreen) { |
262 | if (view->is_fullscreen == fullscreen) { | 273 | if (view->is_fullscreen == fullscreen) { |