don't snap to non-visibles
Dana Jansens danakj@orodu.net
1 files changed,
2 insertions(+),
0 deletions(-)
jump to
M
plugins/resistance.c
→
plugins/resistance.c
@@ -39,6 +39,7 @@ int tl, tt, tr, tb; /* 1 past the target's edges on each side */
target = it->data; if (target == c) continue; /* don't snap to self */ + if (!target->visible) continue; /* don't snap to non-visibles */ tl = target->frame->area.x - 1; tt = target->frame->area.y - 1;@@ -49,6 +50,7 @@ /* snapx and snapy ensure that the window snaps to the top-most
window edge available, without going all the way from bottom-to-top in the stacking list */ + g_print("r %d tl %d\n", r, tl); if (!snapx && cl >= tr && l < tr && l >= tr - resistance) *x = tr, snapx = TRUE; else if (!snapx && cr <= tl && r > tl && r <= tl + resistance)