From 6bd1098c66ae5aa6b68d99b5b7fb7e64dcda9772 Mon Sep 17 00:00:00 2001 From: Olivier Fourdan <fourdan.olivier@wanadoo.fr> Date: Sat, 3 Jun 2006 09:21:45 +0000 Subject: [PATCH] Fix shape and shadow redraw (again). (Old svn revision: 21957) --- src/client.c | 4 ++-- src/compositor.c | 21 ++++++--------------- 2 files changed, 8 insertions(+), 17 deletions(-) diff --git a/src/client.c b/src/client.c index 9a78904ea..38c00fb8e 100644 --- a/src/client.c +++ b/src/client.c @@ -2245,13 +2245,13 @@ clientHideSingle (Client * c, gboolean change_state) /* Adjust to urgency state as the window is not visible */ clientUpdateUrgency (c); } + XUnmapWindow (display_info->dpy, c->window); + XUnmapWindow (display_info->dpy, c->frame); if (change_state) { FLAG_SET (c->flags, CLIENT_FLAG_ICONIFIED); setWMState (display_info, c->window, IconicState); } - XUnmapWindow (display_info->dpy, c->window); - XUnmapWindow (display_info->dpy, c->frame); clientSetNetState (c); } diff --git a/src/compositor.c b/src/compositor.c index acd338cb7..e6f172330 100644 --- a/src/compositor.c +++ b/src/compositor.c @@ -2125,25 +2125,16 @@ compositorHandleShapeNotify (DisplayInfo *display_info, XShapeEvent *ev) { if (ev->kind == ShapeBounding) { - if ((ev->shaped) && !(cw->shaped)) - { - cw->shaped = TRUE; - resize_win (cw, cw->attr.x, cw->attr.y, - ev->width + ev->x, ev->height + ev->y, - cw->attr.border_width, TRUE); - } - else if (!(ev->shaped) && (cw->shaped)) + if (!(ev->shaped) && (cw->shaped)) { - resize_win (cw, cw->attr.x, cw->attr.y, - ev->width + ev->x, ev->height + ev->y, - cw->attr.border_width, TRUE); cw->shaped = FALSE; } - else + resize_win (cw, cw->attr.x, cw->attr.y, + ev->width + ev->x, ev->height + ev->y, + cw->attr.border_width, TRUE); + if ((ev->shaped) && !(cw->shaped)) { - resize_win (cw, cw->attr.x, cw->attr.y, - ev->width + ev->x, ev->height + ev->y, - cw->attr.border_width, TRUE); + cw->shaped = TRUE; } } } -- GitLab