summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJasper St. Pierre <jstpierre@mecheye.net>2014-05-06 08:33:27 -0400
committerKristian Høgsberg <krh@bitplanet.net>2014-05-12 23:34:31 -0700
commitf184c382e89ec71b1b9988a60918110e3fced94e (patch)
treeec86e4249cb0537067cfb66a8261440cd3d51666
parentccf908b078ee7ce51f4cfe727c6eca2f5bb0f79d (diff)
window: Move the resize after interpreting the states
As the protocol says, the states determine how the width and height arguments should be interpreted, so it makes logical sense to do the interpretation after.
-rw-r--r--clients/window.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/clients/window.c b/clients/window.c
index 1d58ad28..4ff6a5a9 100644
--- a/clients/window.c
+++ b/clients/window.c
@@ -3845,14 +3845,6 @@ handle_surface_configure(void *data, struct xdg_surface *xdg_surface,
struct window *window = data;
uint32_t *p;
- if (width > 0 && height > 0) {
- window_schedule_resize(window, width, height);
- } else {
- window_schedule_resize(window,
- window->saved_allocation.width,
- window->saved_allocation.height);
- }
-
window->maximized = 0;
window->fullscreen = 0;
window->resizing = 0;
@@ -3893,6 +3885,14 @@ handle_surface_configure(void *data, struct xdg_surface *xdg_surface,
}
}
+ if (width > 0 && height > 0) {
+ window_schedule_resize(window, width, height);
+ } else {
+ window_schedule_resize(window,
+ window->saved_allocation.width,
+ window->saved_allocation.height);
+ }
+
window->next_attach_serial = serial;
if (window->state_changed_handler)