If a modifier key is held, don't open context menu

D1019 by @gregzaal (minor edits by me).

Thanks for the patch!
This commit is contained in:
julianeisel 2015-01-26 01:57:58 +01:00
parent ce6ba965dc
commit c792e54699
Notes: blender-bot 2023-02-14 03:31:57 +01:00
Referenced by commit b636599fde, Correction to c792e546991bd9: OS-Key should be checked as well
1 changed files with 4 additions and 1 deletions

View File

@ -6392,7 +6392,10 @@ static int ui_do_button(bContext *C, uiBlock *block, uiBut *but, const wmEvent *
return WM_UI_HANDLER_BREAK;
}
/* handle menu */
else if (event->type == RIGHTMOUSE && event->val == KM_PRESS) {
else if (event->type == RIGHTMOUSE &&
event->val == KM_PRESS &&
((event->ctrl + event->alt + event->shift) == 0))
{
/* RMB has two options now */
if (ui_but_menu(C, but)) {
return WM_UI_HANDLER_BREAK;