UI: check if only ctrl is pressed when editing label
Previously, the code only checked that ctrl is pressed. This works, but also allows other keys to be hold at the same time which might conflict with other shortcuts. Now the code also makes sure that shift and alt are not pressed.
This commit is contained in:
@@ -4749,7 +4749,7 @@ static int ui_do_but_TEX(
|
||||
/* Pass, allow file-selector, enter to execute. */
|
||||
}
|
||||
else if (ELEM(but->emboss, UI_EMBOSS_NONE, UI_EMBOSS_NONE_OR_STATUS) &&
|
||||
((event->modifier & KM_CTRL) == 0))
|
||||
((event->modifier & (KM_CTRL | KM_SHIFT | KM_ALT)) != KM_CTRL))
|
||||
{
|
||||
/* Pass. */
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user