Implement EVT_MAXIMIZE support for OS X Cocoa.
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@63417 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -204,6 +204,7 @@ typedef void (*wxOSX_NoResponderHandlerPtr)(NSView* self, SEL _cmd, SEL selector
|
||||
- (void)windowDidBecomeKey:(NSNotification *)notification;
|
||||
- (void)windowDidMove:(NSNotification *)notification;
|
||||
- (BOOL)windowShouldClose:(id)window;
|
||||
- (BOOL)windowShouldZoom:(NSWindow *)window toFrame:(NSRect)newFrame;
|
||||
|
||||
@end
|
||||
|
||||
@@ -327,6 +328,19 @@ typedef void (*wxOSX_NoResponderHandlerPtr)(NSView* self, SEL _cmd, SEL selector
|
||||
return nil;
|
||||
}
|
||||
|
||||
- (BOOL)windowShouldZoom:(NSWindow *)window toFrame:(NSRect)newFrame
|
||||
{
|
||||
wxNonOwnedWindowCocoaImpl* windowimpl = [(wxNSWindow*)window implementation];
|
||||
if ( windowimpl )
|
||||
{
|
||||
wxNonOwnedWindow* wxpeer = windowimpl->GetWXPeer();
|
||||
wxMaximizeEvent event(wxpeer->GetId());
|
||||
event.SetEventObject(wxpeer);
|
||||
return !wxpeer->HandleWindowEvent(event);
|
||||
}
|
||||
return true;
|
||||
}
|
||||
|
||||
@end
|
||||
|
||||
IMPLEMENT_DYNAMIC_CLASS( wxNonOwnedWindowCocoaImpl , wxNonOwnedWindowImpl )
|
||||
|
Reference in New Issue
Block a user