fix titleleft and titleright for fullmax windows without decorations
This commit is contained in:
parent
a8fe821fdd
commit
09f4483ce0
1 changed files with 26 additions and 17 deletions
|
@ -376,6 +376,13 @@ void frame_adjust_area(ObFrame *self, gboolean moved,
|
||||||
|
|
||||||
if (!fake) {
|
if (!fake) {
|
||||||
if (self->bwidth) {
|
if (self->bwidth) {
|
||||||
|
gint titlesides;
|
||||||
|
|
||||||
|
/* height of titleleft and titleright */
|
||||||
|
titlesides = (!self->max_horz ?
|
||||||
|
ob_rr_theme->grip_width :
|
||||||
|
self->size.top - self->bwidth);
|
||||||
|
|
||||||
XMoveResizeWindow(ob_display, self->titletop,
|
XMoveResizeWindow(ob_display, self->titletop,
|
||||||
ob_rr_theme->grip_width + self->bwidth, 0,
|
ob_rr_theme->grip_width + self->bwidth, 0,
|
||||||
/* width + bwidth*2 - bwidth*2 - grips*2 */
|
/* width + bwidth*2 - bwidth*2 - grips*2 */
|
||||||
|
@ -393,27 +400,29 @@ void frame_adjust_area(ObFrame *self, gboolean moved,
|
||||||
ob_rr_theme->grip_width + self->bwidth,
|
ob_rr_theme->grip_width + self->bwidth,
|
||||||
self->bwidth);
|
self->bwidth);
|
||||||
|
|
||||||
XMoveResizeWindow(ob_display, self->titleleft,
|
if (titlesides > 0) {
|
||||||
0, self->bwidth,
|
XMoveResizeWindow(ob_display, self->titleleft,
|
||||||
self->bwidth,
|
0, self->bwidth,
|
||||||
(!self->max_horz ?
|
self->bwidth,
|
||||||
ob_rr_theme->grip_width :
|
titlesides);
|
||||||
self->size.top - self->bwidth));
|
XMoveResizeWindow(ob_display, self->titleright,
|
||||||
XMoveResizeWindow(ob_display, self->titleright,
|
self->client->area.width +
|
||||||
self->client->area.width +
|
self->size.left + self->size.right -
|
||||||
self->size.left + self->size.right -
|
self->bwidth,
|
||||||
self->bwidth,
|
self->bwidth,
|
||||||
self->bwidth,
|
self->bwidth,
|
||||||
self->bwidth,
|
titlesides);
|
||||||
(!self->max_horz ?
|
|
||||||
ob_rr_theme->grip_width :
|
XMapWindow(ob_display, self->titleleft);
|
||||||
self->size.top - self->bwidth));
|
XMapWindow(ob_display, self->titleright);
|
||||||
|
} else {
|
||||||
|
XUnmapWindow(ob_display, self->titleleft);
|
||||||
|
XUnmapWindow(ob_display, self->titleright);
|
||||||
|
}
|
||||||
|
|
||||||
XMapWindow(ob_display, self->titletop);
|
XMapWindow(ob_display, self->titletop);
|
||||||
XMapWindow(ob_display, self->titletopleft);
|
XMapWindow(ob_display, self->titletopleft);
|
||||||
XMapWindow(ob_display, self->titletopright);
|
XMapWindow(ob_display, self->titletopright);
|
||||||
XMapWindow(ob_display, self->titleleft);
|
|
||||||
XMapWindow(ob_display, self->titleright);
|
|
||||||
|
|
||||||
if (self->decorations & OB_FRAME_DECOR_TITLEBAR &&
|
if (self->decorations & OB_FRAME_DECOR_TITLEBAR &&
|
||||||
self->rbwidth)
|
self->rbwidth)
|
||||||
|
|
Loading…
Reference in a new issue