[mouse] Use mwfact lower and upper limits
Signed-off-by: Julien Danjou <julien@danjou.info>
This commit is contained in:
parent
4343771bc7
commit
c3ba206dc6
4
mouse.c
4
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;
|
||||
|
|
Loading…
Reference in New Issue