diff options
Diffstat (limited to 'sway/desktop')
-rw-r--r-- | sway/desktop/output.c | 8 | ||||
-rw-r--r-- | sway/desktop/transaction.c | 2 | ||||
-rw-r--r-- | sway/desktop/xdg_shell.c | 5 | ||||
-rw-r--r-- | sway/desktop/xwayland.c | 5 |
4 files changed, 8 insertions, 12 deletions
diff --git a/sway/desktop/output.c b/sway/desktop/output.c index 18250ae6..2a2e332a 100644 --- a/sway/desktop/output.c +++ b/sway/desktop/output.c | |||
@@ -171,8 +171,8 @@ void output_view_for_each_surface(struct sway_output *output, | |||
171 | - view->geometry.x, | 171 | - view->geometry.x, |
172 | .oy = view->container->surface_y - output->ly | 172 | .oy = view->container->surface_y - output->ly |
173 | - view->geometry.y, | 173 | - view->geometry.y, |
174 | .width = view->container->surface_width, | 174 | .width = view->container->current.content_width, |
175 | .height = view->container->surface_height, | 175 | .height = view->container->current.content_height, |
176 | .rotation = 0, // TODO | 176 | .rotation = 0, // TODO |
177 | }; | 177 | }; |
178 | 178 | ||
@@ -191,8 +191,8 @@ void output_view_for_each_popup(struct sway_output *output, | |||
191 | - view->geometry.x, | 191 | - view->geometry.x, |
192 | .oy = view->container->surface_y - output->ly | 192 | .oy = view->container->surface_y - output->ly |
193 | - view->geometry.y, | 193 | - view->geometry.y, |
194 | .width = view->container->surface_width, | 194 | .width = view->container->current.content_width, |
195 | .height = view->container->surface_height, | 195 | .height = view->container->current.content_height, |
196 | .rotation = 0, // TODO | 196 | .rotation = 0, // TODO |
197 | }; | 197 | }; |
198 | 198 | ||
diff --git a/sway/desktop/transaction.c b/sway/desktop/transaction.c index 053312a5..7b9ab586 100644 --- a/sway/desktop/transaction.c +++ b/sway/desktop/transaction.c | |||
@@ -267,8 +267,6 @@ static void apply_container_state(struct sway_container *container, | |||
267 | } else { | 267 | } else { |
268 | container->surface_y = container->current.content_y; | 268 | container->surface_y = container->current.content_y; |
269 | } | 269 | } |
270 | container->surface_width = container->current.content_width; | ||
271 | container->surface_height = container->current.content_height; | ||
272 | } | 270 | } |
273 | 271 | ||
274 | if (!container->node.destroying) { | 272 | if (!container->node.destroying) { |
diff --git a/sway/desktop/xdg_shell.c b/sway/desktop/xdg_shell.c index 01574577..7775f660 100644 --- a/sway/desktop/xdg_shell.c +++ b/sway/desktop/xdg_shell.c | |||
@@ -282,10 +282,9 @@ static void handle_commit(struct wl_listener *listener, void *data) { | |||
282 | } else { | 282 | } else { |
283 | struct wlr_box new_geo; | 283 | struct wlr_box new_geo; |
284 | wlr_xdg_surface_get_geometry(xdg_surface, &new_geo); | 284 | wlr_xdg_surface_get_geometry(xdg_surface, &new_geo); |
285 | struct sway_container *con = view->container; | ||
286 | 285 | ||
287 | if ((new_geo.width != con->surface_width || | 286 | if ((new_geo.width != view->geometry.width || |
288 | new_geo.height != con->surface_height)) { | 287 | new_geo.height != view->geometry.height)) { |
289 | // The view has unexpectedly sent a new size | 288 | // The view has unexpectedly sent a new size |
290 | desktop_damage_view(view); | 289 | desktop_damage_view(view); |
291 | view_update_size(view, new_geo.width, new_geo.height); | 290 | view_update_size(view, new_geo.width, new_geo.height); |
diff --git a/sway/desktop/xwayland.c b/sway/desktop/xwayland.c index 4bf5b6b8..b51bbb74 100644 --- a/sway/desktop/xwayland.c +++ b/sway/desktop/xwayland.c | |||
@@ -371,10 +371,9 @@ static void handle_commit(struct wl_listener *listener, void *data) { | |||
371 | } else { | 371 | } else { |
372 | struct wlr_box new_geo; | 372 | struct wlr_box new_geo; |
373 | get_geometry(view, &new_geo); | 373 | get_geometry(view, &new_geo); |
374 | struct sway_container *con = view->container; | ||
375 | 374 | ||
376 | if ((new_geo.width != con->surface_width || | 375 | if ((new_geo.width != view->geometry.width || |
377 | new_geo.height != con->surface_height)) { | 376 | new_geo.height != view->geometry.height)) { |
378 | // The view has unexpectedly sent a new size | 377 | // The view has unexpectedly sent a new size |
379 | // eg. The Firefox "Save As" dialog when downloading a file | 378 | // eg. The Firefox "Save As" dialog when downloading a file |
380 | desktop_damage_view(view); | 379 | desktop_damage_view(view); |