diff options
author | Carsten Haitzler (Rasterman) <raster@rasterman.com> | 2021-09-23 12:51:48 +0100 |
---|---|---|
committer | Carsten Haitzler (Rasterman) <raster@rasterman.com> | 2021-09-23 12:51:48 +0100 |
commit | 32255d012259fe8bcbd84aa525b4ee5ceb11adfb (patch) | |
tree | 9bd847e8527e06e9bed22a452e5a076d35f65e97 | |
parent | c9070fc03fd0c106094e0eef4fa6b056dd50d9b3 (diff) | |
download | enlightenment-32255d012259fe8bcbd84aa525b4ee5ceb11adfb.tar.gz |
e - fix a null csd property on a ssd x win - new chrome does odd things
new chrome versions now set a CSd gtk property of 0 0 0 0 on
windows.... but set it later on thus confusing e into seeing
information changes for csd frame insets for a window that has no csd
frame but is ssd! this drops into a logic hole of "this shouldn't
happen" and weird stuff does happen. avoid this weirdness and just
assume a ssd window as normal then.
@fix
-rw-r--r-- | src/bin/e_comp_x.c | 34 |
1 files changed, 28 insertions, 6 deletions
diff --git a/src/bin/e_comp_x.c b/src/bin/e_comp_x.c index 69dc1d333c..fbb61d6465 100644 --- a/src/bin/e_comp_x.c +++ b/src/bin/e_comp_x.c @@ -4833,12 +4833,34 @@ _e_comp_x_hook_client_fetch(void *d EINA_UNUSED, E_Client *ec) * this area should not be accounted for in sizing or * placement calculations. */ - e_comp_object_frame_geometry_set(ec->frame, - -extents[0], -extents[1], -extents[2], -extents[3]); - if (ec->override && - (ec->x == ec->comp_data->initial_attributes.x) && - (ec->y == ec->comp_data->initial_attributes.y)) - e_comp_object_frame_xy_adjust(ec->frame, ec->x, ec->y, &ec->x, &ec->y); + if (count >= 4) + { + unsigned int extentscurrent; + unsigned int extentsall = + extents[0] | extents[1] | extents[2] | extents[3]; + int insl = 0, insr = 0, inst = 0, insb = 0; + e_comp_object_frame_geometry_get(ec->frame, &insl, &insr, + &inst, &insb); + extentscurrent = insl | insr | inst | insb; + + extentsall = !!extentsall; + extentscurrent = !!extentscurrent; + if ((!e_comp_object_frame_exists(ec->frame)) && + (( extentsall && extentscurrent) || + (!extentsall && extentscurrent) || + ( extentsall && !extentscurrent))) + { + e_comp_object_frame_geometry_set(ec->frame, + -extents[0], + -extents[1], + -extents[2], + -extents[3]); + if (ec->override && + (ec->x == ec->comp_data->initial_attributes.x) && + (ec->y == ec->comp_data->initial_attributes.y)) + e_comp_object_frame_xy_adjust(ec->frame, ec->x, ec->y, &ec->x, &ec->y); + } + } free(extents); } cd->fetch_gtk_frame_extents = 0; |