diff options
| author | bakkeby <[email protected]> | 2020-06-25 11:56:41 +0200 |
|---|---|---|
| committer | bakkeby <[email protected]> | 2020-06-25 11:56:41 +0200 |
| commit | c14a51524b103de1068391786d9643a8af77f796 (patch) | |
| tree | 1bb2ba47d6cc4bbb2f02281bf1a6f619a2442ce6 /patch | |
| parent | 5a4c350b9cdbee170c60354643d33541d469fe2b (diff) | |
| download | dwm-flexipatch-c14a51524b103de1068391786d9643a8af77f796.tar.gz dwm-flexipatch-c14a51524b103de1068391786d9643a8af77f796.zip | |
Adding cursor icons for resizecorners, resizepoint, dragmfact and dragcfact
Diffstat (limited to 'patch')
| -rw-r--r-- | patch/dragcfact.c | 2 | ||||
| -rw-r--r-- | patch/dragmfact.c | 11 |
2 files changed, 6 insertions, 7 deletions
diff --git a/patch/dragcfact.c b/patch/dragcfact.c index 9d20a2b..a99f046 100644 --- a/patch/dragcfact.c +++ b/patch/dragcfact.c @@ -25,7 +25,7 @@ dragcfact(const Arg *arg) restack(selmon); if (XGrabPointer(dpy, root, False, MOUSEMASK, GrabModeAsync, GrabModeAsync, - None, cursor[CurResize]->cursor, CurrentTime) != GrabSuccess) + None, cursor[CurIronCross]->cursor, CurrentTime) != GrabSuccess) return; XWarpPointer(dpy, None, c->win, 0, 0, 0, 0, c->w/2, c->h/2); diff --git a/patch/dragmfact.c b/patch/dragmfact.c index 3bb111f..26867f5 100644 --- a/patch/dragmfact.c +++ b/patch/dragmfact.c @@ -61,7 +61,7 @@ dragmfact(const Arg *arg) if (layout == SPLIT_HORIZONTAL || layout == SPLIT_HORIZONTAL_DUAL_STACK) horizontal = 1; - else if (layout == SPLIT_CENTERED_VERTICAL) + else if (layout == SPLIT_CENTERED_VERTICAL && (n - m->nmaster) > 1) center = 1; else if (layout == FLOATING_MASTER) { center = 1; @@ -75,7 +75,7 @@ dragmfact(const Arg *arg) } #endif // FLEXTILE_DELUXE_LAYOUT #if CENTEREDMASTER_LAYOUT - else if (m->lt[m->sellt]->arrange == ¢eredmaster) + else if (m->lt[m->sellt]->arrange == ¢eredmaster && (n - m->nmaster) > 1) center = 1; #endif // CENTEREDMASTER_LAYOUT #if CENTEREDFLOATINGMASTER_LAYOUT @@ -91,10 +91,6 @@ dragmfact(const Arg *arg) horizontal = 1; #endif // BSTACKHORIZ_LAYOUT - if (XGrabPointer(dpy, root, False, MOUSEMASK, GrabModeAsync, GrabModeAsync, - None, cursor[CurResize]->cursor, CurrentTime) != GrabSuccess) - return; - #if VANITYGAPS_PATCH ay += oh; ax += ov; @@ -148,6 +144,9 @@ dragmfact(const Arg *arg) py = ay + ah / 2; } + if (XGrabPointer(dpy, root, False, MOUSEMASK, GrabModeAsync, GrabModeAsync, + None, cursor[horizontal ? CurResizeVertArrow : CurResizeHorzArrow]->cursor, CurrentTime) != GrabSuccess) + return; XWarpPointer(dpy, None, root, 0, 0, 0, 0, px, py); do { |
