aboutsummaryrefslogtreecommitdiffstats
path: root/src/macterm.c
diff options
context:
space:
mode:
authorSteven Tamm2004-06-29 06:23:08 +0000
committerSteven Tamm2004-06-29 06:23:08 +0000
commitc61278bbde089da22d4a774fe348536c172c20da (patch)
tree0918ebf077e006133087dff48744fe0569f166f2 /src/macterm.c
parentc3762cbd4b8d9569291a20465315a024881eb17c (diff)
downloademacs-c61278bbde089da22d4a774fe348536c172c20da.tar.gz
emacs-c61278bbde089da22d4a774fe348536c172c20da.zip
macterm.c (mac_get_emulated_btn)
(mac_event_to_emacs_modifiers): Fix emulated mouse button support to correctly mask out modifiers.
Diffstat (limited to 'src/macterm.c')
-rw-r--r--src/macterm.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/macterm.c b/src/macterm.c
index bef37addaa6..b9584be50bc 100644
--- a/src/macterm.c
+++ b/src/macterm.c
@@ -7018,7 +7018,7 @@ mac_get_emulated_btn ( UInt32 modifiers )
7018 int result = 0; 7018 int result = 0;
7019 if (!NILP (Vmac_emulate_three_button_mouse)) { 7019 if (!NILP (Vmac_emulate_three_button_mouse)) {
7020 int cmdIs3 = !EQ (Vmac_emulate_three_button_mouse, Qreverse); 7020 int cmdIs3 = !EQ (Vmac_emulate_three_button_mouse, Qreverse);
7021 if (modifiers & controlKey) 7021 if (modifiers & cmdKey)
7022 result = cmdIs3 ? 2 : 1; 7022 result = cmdIs3 ? 2 : 1;
7023 else if (modifiers & optionKey) 7023 else if (modifiers & optionKey)
7024 result = cmdIs3 ? 1 : 2; 7024 result = cmdIs3 ? 1 : 2;
@@ -7038,7 +7038,7 @@ mac_event_to_emacs_modifiers (EventRef eventRef)
7038 if (!NILP (Vmac_emulate_three_button_mouse) && 7038 if (!NILP (Vmac_emulate_three_button_mouse) &&
7039 GetEventClass(eventRef) == kEventClassMouse) 7039 GetEventClass(eventRef) == kEventClassMouse)
7040 { 7040 {
7041 mods &= ~(optionKey & cmdKey); 7041 mods &= ~(optionKey | cmdKey);
7042 } 7042 }
7043 return mac_to_emacs_modifiers (mods); 7043 return mac_to_emacs_modifiers (mods);
7044} 7044}