X-Git-Url: https://git.dogcows.com/gitweb?a=blobdiff_plain;f=openbox%2Fframe.c;h=0f9e581f964a28f9ec02259008084e3eb6b9ebc9;hb=bfb0c916718cd6f68ef100841a625b06602f616b;hp=93dbefedef3bfb543fd5a2493d43d9e61d2367f8;hpb=52480d87e4e6ca3cb9731748847e11e80af40f47;p=chaz%2Fopenbox diff --git a/openbox/frame.c b/openbox/frame.c index 93dbefed..0f9e581f 100644 --- a/openbox/frame.c +++ b/openbox/frame.c @@ -717,7 +717,10 @@ void frame_adjust_area(ObFrame *self, gboolean moved, XUnmapWindow(ob_display, self->handle); } - if (self->bwidth && !self->max_horz) { + if (self->bwidth && !self->max_horz && + (self->client->area.height + self->size.top + + self->size.bottom) > ob_rr_theme->grip_width * 2) + { XMoveResizeWindow(ob_display, self->left, 0, self->bwidth + ob_rr_theme->grip_width, @@ -730,7 +733,10 @@ void frame_adjust_area(ObFrame *self, gboolean moved, } else XUnmapWindow(ob_display, self->left); - if (self->bwidth && !self->max_horz) { + if (self->bwidth && !self->max_horz && + (self->client->area.height + self->size.top + + self->size.bottom) > ob_rr_theme->grip_width * 2) + { XMoveResizeWindow(ob_display, self->right, self->client->area.width + self->cbwidth_l + self->cbwidth_r + self->bwidth, @@ -1533,6 +1539,13 @@ void frame_rect_to_frame(ObFrame *self, Rect *r) frame_client_gravity(self, &r->x, &r->y); } +void frame_rect_to_client(ObFrame *self, Rect *r) +{ + r->width -= self->size.left + self->size.right; + r->height -= self->size.top + self->size.bottom; + frame_frame_gravity(self, &r->x, &r->y); +} + static void flash_done(gpointer data) { ObFrame *self = data;