|
|
@ -58,6 +58,7 @@ static void
|
|
|
|
resizemouse(Client *c)
|
|
|
|
resizemouse(Client *c)
|
|
|
|
{
|
|
|
|
{
|
|
|
|
int ocx, ocy;
|
|
|
|
int ocx, ocy;
|
|
|
|
|
|
|
|
int nw, nh;
|
|
|
|
Corner sticky;
|
|
|
|
Corner sticky;
|
|
|
|
XEvent ev;
|
|
|
|
XEvent ev;
|
|
|
|
|
|
|
|
|
|
|
@ -76,7 +77,9 @@ resizemouse(Client *c)
|
|
|
|
break;
|
|
|
|
break;
|
|
|
|
case MotionNotify:
|
|
|
|
case MotionNotify:
|
|
|
|
XSync(dpy, False);
|
|
|
|
XSync(dpy, False);
|
|
|
|
|
|
|
|
if((nw = abs(ocx - ev.xmotion.x)))
|
|
|
|
c->w = abs(ocx - ev.xmotion.x);
|
|
|
|
c->w = abs(ocx - ev.xmotion.x);
|
|
|
|
|
|
|
|
if((nh = abs(ocy - ev.xmotion.y)))
|
|
|
|
c->h = abs(ocy - ev.xmotion.y);
|
|
|
|
c->h = abs(ocy - ev.xmotion.y);
|
|
|
|
c->x = (ocx <= ev.xmotion.x) ? ocx : ocx - c->w;
|
|
|
|
c->x = (ocx <= ev.xmotion.x) ? ocx : ocx - c->w;
|
|
|
|
c->y = (ocy <= ev.xmotion.y) ? ocy : ocy - c->h;
|
|
|
|
c->y = (ocy <= ev.xmotion.y) ? ocy : ocy - c->h;
|
|
|
|