fixing right click
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26731 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -157,7 +157,12 @@ static pascal OSStatus KeyboardEventHandler( EventHandlerCallRef handler , Event
|
|||||||
{
|
{
|
||||||
OSStatus result = eventNotHandledErr ;
|
OSStatus result = eventNotHandledErr ;
|
||||||
|
|
||||||
|
wxTopLevelWindow* tlw = (wxTopLevelWindow*) data ;
|
||||||
|
|
||||||
wxWindow* focus = wxWindow::FindFocus() ;
|
wxWindow* focus = wxWindow::FindFocus() ;
|
||||||
|
if ( focus == NULL )
|
||||||
|
return result ;
|
||||||
|
|
||||||
char charCode ;
|
char charCode ;
|
||||||
UInt32 keyCode ;
|
UInt32 keyCode ;
|
||||||
UInt32 modifiers ;
|
UInt32 modifiers ;
|
||||||
@@ -294,7 +299,7 @@ static void SetupMouseEvent( wxMouseEvent &wxevent , wxMacCarbonEvent &cEvent )
|
|||||||
if ( button == kEventMouseButtonSecondary )
|
if ( button == kEventMouseButtonSecondary )
|
||||||
{
|
{
|
||||||
if (cEvent.GetKind() == kEventMouseDown )
|
if (cEvent.GetKind() == kEventMouseDown )
|
||||||
wxevent.SetEventType( clickCount > 1 ? wxEVT_RIGHT_DOWN : wxEVT_RIGHT_DCLICK ) ;
|
wxevent.SetEventType( clickCount > 1 ? wxEVT_RIGHT_DCLICK : wxEVT_RIGHT_DOWN ) ;
|
||||||
else if ( cEvent.GetKind() == kEventMouseUp )
|
else if ( cEvent.GetKind() == kEventMouseUp )
|
||||||
wxevent.SetEventType(wxEVT_RIGHT_UP ) ;
|
wxevent.SetEventType(wxEVT_RIGHT_UP ) ;
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user