|
|
|
@ -380,7 +380,6 @@ void
|
|
|
|
|
arrange(void) {
|
|
|
|
|
Monitor *m;
|
|
|
|
|
|
|
|
|
|
/* optimise two loops into one, check focus(NULL) */
|
|
|
|
|
for(m = mons; m; m = m->next)
|
|
|
|
|
showhide(m->stack);
|
|
|
|
|
focus(NULL);
|
|
|
|
@ -909,9 +908,7 @@ gettextprop(Window w, Atom atom, char *text, unsigned int size) {
|
|
|
|
|
if(name.encoding == XA_STRING)
|
|
|
|
|
strncpy(text, (char *)name.value, size - 1);
|
|
|
|
|
else {
|
|
|
|
|
if(XmbTextPropertyToTextList(dpy, &name, &list, &n) >= Success
|
|
|
|
|
&& n > 0 && *list)
|
|
|
|
|
{
|
|
|
|
|
if(XmbTextPropertyToTextList(dpy, &name, &list, &n) >= Success && n > 0 && *list) {
|
|
|
|
|
strncpy(text, *list, size - 1);
|
|
|
|
|
XFreeStringList(list);
|
|
|
|
|
}
|
|
|
|
@ -1294,7 +1291,8 @@ resizemouse(const Arg *arg) {
|
|
|
|
|
nw = MAX(ev.xmotion.x - ocx - 2 * c->bw + 1, 1);
|
|
|
|
|
nh = MAX(ev.xmotion.y - ocy - 2 * c->bw + 1, 1);
|
|
|
|
|
if(snap && nw >= selmon->wx && nw <= selmon->wx + selmon->ww
|
|
|
|
|
&& nh >= selmon->wy && nh <= selmon->wy + selmon->wh) {
|
|
|
|
|
&& nh >= selmon->wy && nh <= selmon->wy + selmon->wh)
|
|
|
|
|
{
|
|
|
|
|
if(!c->isfloating && selmon->lt[selmon->sellt]->arrange
|
|
|
|
|
&& (abs(nw - c->w) > snap || abs(nh - c->h) > snap))
|
|
|
|
|
togglefloating(NULL);
|
|
|
|
|