Finally, the "Emulate 3 buttons" button in the userprefs actually

*does* turn ALT-LEFTMOUSE emulation on and off :)
This commit is contained in:
Alexander Ewering 2003-09-10 02:46:22 +00:00
parent 422f4faa1b
commit 4646b046b6

@ -42,6 +42,8 @@
#include "MEM_guardedalloc.h"
#include "DNA_userdef_types.h" /* U.flag & TWOBUTTONMOUSE */
#include "BLI_blenlib.h"
#include "GHOST_C-api.h"
@ -405,7 +407,8 @@ static int event_proc(GHOST_EventHandle evt, GHOST_TUserDataPtr private) {
if (val) {
if (win->commandqual) {
bbut= win->faked_mbut= RIGHTMOUSE;
} else if (win->lqual & LR_ALTKEY) {
} else if ((win->lqual & LR_ALTKEY) && (U.flag & TWOBUTTONMOUSE)) {
/* finally, it actually USES the userpref! :) -intrr */
bbut= win->faked_mbut= MIDDLEMOUSE;
}
} else {