@ -150,6 +150,7 @@ buttonpress(XEvent *e)
static void
static void
configurerequest ( XEvent * e )
configurerequest ( XEvent * e )
{
{
int ox , oy , ow , oh ;
unsigned long newmask ;
unsigned long newmask ;
Client * c ;
Client * c ;
XConfigureRequestEvent * ev = & e - > xconfigurerequest ;
XConfigureRequestEvent * ev = & e - > xconfigurerequest ;
@ -157,6 +158,10 @@ configurerequest(XEvent *e)
XWindowChanges wc ;
XWindowChanges wc ;
if ( ( c = getclient ( ev - > window ) ) ) {
if ( ( c = getclient ( ev - > window ) ) ) {
ox = c - > x ;
oy = c - > y ;
ow = c - > w ;
oh = c - > h ;
gravitate ( c , True ) ;
gravitate ( c , True ) ;
if ( ev - > value_mask & CWX )
if ( ev - > value_mask & CWX )
c - > x = ev - > x ;
c - > x = ev - > x ;
@ -191,8 +196,13 @@ configurerequest(XEvent *e)
XSendEvent ( dpy , c - > win , True , NoEventMask , & synev ) ;
XSendEvent ( dpy , c - > win , True , NoEventMask , & synev ) ;
}
}
XSync ( dpy , False ) ;
XSync ( dpy , False ) ;
if ( c - > isfloat )
if ( c - > isfloat | | c - > ismax ) {
resize ( c , False , TopLeft ) ;
resize ( c , False , TopLeft ) ;
c - > x = ox ;
c - > y = oy ;
c - > w = ow ;
c - > h = oh ;
}
else
else
arrange ( NULL ) ;
arrange ( NULL ) ;
}
}