From 1b321567bf4db59f50e5d4be363041ec68aff6d0 Mon Sep 17 00:00:00 2001 From: Mike Blumenkrantz Date: Thu, 22 Jan 2015 23:43:42 -0500 Subject: [PATCH] simplify wl xdg/shell configure functions setting changes.XYZ is generally bad and shouldn't be done. in this case, it was obscuring an infinite render resize loop #barrel --- src/modules/wl_desktop_shell/e_mod_main.c | 42 ++--------------------- 1 file changed, 2 insertions(+), 40 deletions(-) diff --git a/src/modules/wl_desktop_shell/e_mod_main.c b/src/modules/wl_desktop_shell/e_mod_main.c index c76e9fc11..d91ca5778 100644 --- a/src/modules/wl_desktop_shell/e_mod_main.c +++ b/src/modules/wl_desktop_shell/e_mod_main.c @@ -475,26 +475,7 @@ _e_shell_surface_configure(struct wl_resource *resource, Evas_Coord x, Evas_Coor } } - if ((ec->client.x != x) || (ec->client.y != y)) - { - ec->client.x = x; - ec->client.y = y; - if (ec->frame) - e_comp_object_frame_xy_adjust(ec->frame, x, y, &ec->x, &ec->y); - ec->changes.pos = EINA_TRUE; - } - -// if ((ec->client.w != w) || (ec->client.h != h)) - { - ec->client.w = w; - ec->client.h = h; - if (ec->frame) - e_comp_object_frame_wh_adjust(ec->frame, w, h, &ec->w, &ec->h); - ec->changes.size = EINA_TRUE; - } - - if ((ec->changes.size) || (ec->changes.pos)) - EC_CHANGED(ec); + e_client_util_move_resize_without_frame(ec, x, y, w, h); } static void @@ -1057,28 +1038,9 @@ _e_xdg_shell_surface_configure(struct wl_resource *resource, Evas_Coord x, Evas_ } } - if ((ec->client.x != x) || (ec->client.y != y)) - { - ec->client.x = x; - ec->client.y = y; - if (ec->frame) - e_comp_object_frame_xy_adjust(ec->frame, x, y, &ec->x, &ec->y); - ec->changes.pos = EINA_TRUE; - } - -// if ((ec->client.w != w) || (ec->client.h != h)) - { - ec->client.w = w; - ec->client.h = h; - if (ec->frame) - e_comp_object_frame_wh_adjust(ec->frame, w, h, &ec->w, &ec->h); - ec->changes.size = EINA_TRUE; - } + e_client_util_move_resize_without_frame(ec, x, y, w, h); /* TODO: ack configure ?? */ - - if ((ec->changes.pos) || (ec->changes.size)) - EC_CHANGED(ec); } static void