diff --git a/mouse.c b/mouse.c index 759ad8b0f..daef750ec 100644 --- a/mouse.c +++ b/mouse.c @@ -372,8 +372,8 @@ uicb_client_resizemouse(int screen, char *arg __attribute__ ((unused))) mwfact = (double) (ev.xmotion.y - area.y) / area.height; else mwfact = 1 - (double) (ev.xmotion.y - area.y) / area.height; - if(mwfact < 0.1) mwfact = 0.1; - else if(mwfact > 0.9) mwfact = 0.9; + mwfact = MAX(globalconf.screens[screen].mwfact_lower_limit, + MIN(globalconf.screens[screen].mwfact_upper_limit, mwfact)); if(fabs(curtags[0]->mwfact - mwfact) >= 0.01) { curtags[0]->mwfact = mwfact;