UI: fix Ctrl-Wheel to change button values

This commit is contained in:
Campbell Barton 2018-06-19 18:35:55 +02:00
parent 1292aae5c0
commit 44611ab860
Notes: blender-bot 2023-02-14 05:43:06 +01:00
Referenced by issue #55548, Blender 2.80 is not starting as Maximized Window
1 changed files with 2 additions and 0 deletions

View File

@ -4333,10 +4333,12 @@ static int ui_do_but_NUM(
retval = WM_UI_HANDLER_BREAK; /* allow accumulating values, otherwise scrolling gets preference */
else if (type == WHEELDOWNMOUSE && event->ctrl) {
mx = but->rect.xmin;
but->drawflag |= UI_BUT_ACTIVE_LEFT;
click = 1;
}
else if (type == WHEELUPMOUSE && event->ctrl) {
mx = but->rect.xmax;
but->drawflag |= UI_BUT_ACTIVE_RIGHT;
click = 1;
}
else if (event->val == KM_PRESS) {