summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorbl0ckeduser <[email protected]>2014-06-22 11:43:37 -0400
committerinfirit <[email protected]>2015-08-29 13:41:54 +0200
commitb53fb913abe7da1e8d56bd50151f673c90cf121d (patch)
treeddee6e38c8aa7c6983e408f929e111d0c6bc2b9b /src
parent5890f59f1510e8cd3ff3b9440140d917a1c9e2ff (diff)
downloadmarco-b53fb913abe7da1e8d56bd50151f673c90cf121d.tar.bz2
marco-b53fb913abe7da1e8d56bd50151f673c90cf121d.tar.xz
Repaint area of deleted shadowed windows (fixes #27)
Diffstat (limited to 'src')
-rw-r--r--src/compositor/compositor-xrender.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/compositor/compositor-xrender.c b/src/compositor/compositor-xrender.c
index 7d31f303..156be239 100644
--- a/src/compositor/compositor-xrender.c
+++ b/src/compositor/compositor-xrender.c
@@ -1553,6 +1553,25 @@ free_win (MetaCompWindow *cw,
MetaDisplay *display = meta_screen_get_display (cw->screen);
Display *xdisplay = meta_display_get_xdisplay (display);
MetaCompScreen *info = meta_screen_get_compositor_data (cw->screen);
+ XRectangle r;
+ XserverRegion region;
+
+ /*
+ * If we are deleting a window with a compositor shadow,
+ * trigger a repaint of the area it was covering.
+ * This fixes an issue where the shadow beneath a
+ * (GTK3) tooltip was not being erased after the tooltip
+ * disappeared.
+ */
+ if (cw->shadow) {
+ r.x = cw->attrs.x + cw->shadow_dx;
+ r.y = cw->attrs.y + cw->shadow_dy;
+ r.width = cw->attrs.width + cw->shadow_width;
+ r.height = cw->attrs.height + cw->shadow_height;
+ region = XFixesCreateRegion (xdisplay, &r, 1);
+ add_damage(cw->screen, region);
+ }
+
#ifdef HAVE_NAME_WINDOW_PIXMAP
if (have_name_window_pixmap (display))