fix for not sending a native click to a control if it is not enabled (does an enable itself)
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@28980 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -535,13 +535,16 @@ pascal OSStatus wxMacTopLevelMouseEventHandler( EventHandlerCallRef handler , Ev
|
|||||||
(FindControlUnderMouse(windowMouseLocation , window , &dummyPart) !=
|
(FindControlUnderMouse(windowMouseLocation , window , &dummyPart) !=
|
||||||
wxMacFindControlUnderMouse( windowMouseLocation , window , &dummyPart ) ) )
|
wxMacFindControlUnderMouse( windowMouseLocation , window , &dummyPart ) ) )
|
||||||
{
|
{
|
||||||
EventModifiers modifiers = cEvent.GetParameter<EventModifiers>(kEventParamKeyModifiers, typeUInt32) ;
|
if ( currentMouseWindow->MacIsReallyEnabled() )
|
||||||
Point clickLocation = windowMouseLocation ;
|
{
|
||||||
#if TARGET_API_MAC_OSX
|
EventModifiers modifiers = cEvent.GetParameter<EventModifiers>(kEventParamKeyModifiers, typeUInt32) ;
|
||||||
currentMouseWindow->MacRootWindowToWindow( &clickLocation.h , &clickLocation.v ) ;
|
Point clickLocation = windowMouseLocation ;
|
||||||
#endif
|
#if TARGET_API_MAC_OSX
|
||||||
HandleControlClick( (ControlRef) currentMouseWindow->GetHandle() , clickLocation ,
|
currentMouseWindow->MacRootWindowToWindow( &clickLocation.h , &clickLocation.v ) ;
|
||||||
modifiers , (ControlActionUPP ) -1 ) ;
|
#endif
|
||||||
|
HandleControlClick( (ControlRef) currentMouseWindow->GetHandle() , clickLocation ,
|
||||||
|
modifiers , (ControlActionUPP ) -1 ) ;
|
||||||
|
}
|
||||||
result = noErr ;
|
result = noErr ;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user