From: Stefan Csomor Date: Thu, 18 Sep 2003 12:37:53 +0000 (+0000) Subject: support for true two button mouse under OSX X-Git-Url: https://git.saurik.com/wxWidgets.git/commitdiff_plain/01c185668f4d56cf1f71a54a658e5bcecde2a531 support for true two button mouse under OSX git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@23665 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- diff --git a/src/mac/carbon/toplevel.cpp b/src/mac/carbon/toplevel.cpp index 67b1307bd7..bf1864f056 100644 --- a/src/mac/carbon/toplevel.cpp +++ b/src/mac/carbon/toplevel.cpp @@ -264,6 +264,11 @@ pascal OSStatus MouseEventHandler( EventHandlerCallRef handler , EventRef event if ( button == 0 || GetEventKind( event ) == kEventMouseUp ) modifiers += btnState ; + // temporary hack to support true two button mouse + if ( button == kEventMouseButtonSecondary ) + { + modifiers |= controlKey ; + } WindowRef window ; short windowPart = ::FindWindow(point, &window); diff --git a/src/mac/toplevel.cpp b/src/mac/toplevel.cpp index 67b1307bd7..bf1864f056 100644 --- a/src/mac/toplevel.cpp +++ b/src/mac/toplevel.cpp @@ -264,6 +264,11 @@ pascal OSStatus MouseEventHandler( EventHandlerCallRef handler , EventRef event if ( button == 0 || GetEventKind( event ) == kEventMouseUp ) modifiers += btnState ; + // temporary hack to support true two button mouse + if ( button == kEventMouseButtonSecondary ) + { + modifiers |= controlKey ; + } WindowRef window ; short windowPart = ::FindWindow(point, &window);