aboutsummaryrefslogtreecommitdiffstats
path: root/sway/desktop/xwayland.c
diff options
context:
space:
mode:
authorLibravatar Rostislav Pehlivanov <atomnuker@gmail.com>2018-06-27 17:53:13 +0100
committerLibravatar Rostislav Pehlivanov <atomnuker@gmail.com>2018-06-30 11:10:47 +0100
commite0d0e8f840271ab12533cb16c9a7ccba237adcb3 (patch)
treea81bf679fc25f89cc09516e1920c4496b2e4c2f8 /sway/desktop/xwayland.c
parentMerge pull request #2173 from emersion/fix-floating-no-frame-event (diff)
downloadsway-e0d0e8f840271ab12533cb16c9a7ccba237adcb3.tar.gz
sway-e0d0e8f840271ab12533cb16c9a7ccba237adcb3.tar.zst
sway-e0d0e8f840271ab12533cb16c9a7ccba237adcb3.zip
Revert "Don't unmaximize floating views"
Diffstat (limited to 'sway/desktop/xwayland.c')
-rw-r--r--sway/desktop/xwayland.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/sway/desktop/xwayland.c b/sway/desktop/xwayland.c
index df5f6698..fcc8164f 100644
--- a/sway/desktop/xwayland.c
+++ b/sway/desktop/xwayland.c
@@ -199,6 +199,14 @@ static void set_activated(struct sway_view *view, bool activated) {
199 wlr_xwayland_surface_activate(surface, activated); 199 wlr_xwayland_surface_activate(surface, activated);
200} 200}
201 201
202static void set_tiled(struct sway_view *view, bool tiled) {
203 if (xwayland_view_from_view(view) == NULL) {
204 return;
205 }
206 struct wlr_xwayland_surface *surface = view->wlr_xwayland_surface;
207 wlr_xwayland_surface_set_maximized(surface, tiled);
208}
209
202static void set_fullscreen(struct sway_view *view, bool fullscreen) { 210static void set_fullscreen(struct sway_view *view, bool fullscreen) {
203 if (xwayland_view_from_view(view) == NULL) { 211 if (xwayland_view_from_view(view) == NULL) {
204 return; 212 return;
@@ -265,6 +273,7 @@ static const struct sway_view_impl view_impl = {
265 .get_int_prop = get_int_prop, 273 .get_int_prop = get_int_prop,
266 .configure = configure, 274 .configure = configure,
267 .set_activated = set_activated, 275 .set_activated = set_activated,
276 .set_tiled = set_tiled,
268 .set_fullscreen = set_fullscreen, 277 .set_fullscreen = set_fullscreen,
269 .wants_floating = wants_floating, 278 .wants_floating = wants_floating,
270 .close = _close, 279 .close = _close,
@@ -309,7 +318,6 @@ static void handle_map(struct wl_listener *listener, void *data) {
309 xwayland_view->commit.notify = handle_commit; 318 xwayland_view->commit.notify = handle_commit;
310 319
311 // Put it back into the tree 320 // Put it back into the tree
312 wlr_xwayland_surface_set_maximized(xsurface, true);
313 view_map(view, xsurface->surface); 321 view_map(view, xsurface->surface);
314 322
315 if (xsurface->fullscreen) { 323 if (xsurface->fullscreen) {