1 ///////////////////////////////////////////////////////////////////////////////
2 // Name: wx/cocoa/NSWindow.h
3 // Purpose: wxCocoaNSWindow class
4 // Author: David Elliott
8 // Copyright: (c) 2003 David Elliott
9 // Licence: wxWindows license
10 ///////////////////////////////////////////////////////////////////////////////
12 #ifndef __WX_COCOA_NSWINDOW_H__
13 #define __WX_COCOA_NSWINDOW_H__
15 #include "wx/hashmap.h"
16 #include "wx/cocoa/ObjcAssociate.h"
18 WX_DECLARE_OBJC_HASHMAP(NSWindow
);
20 class WXDLLEXPORT wxMenuBar
;
24 /* NSWindow is a rather special case and requires some extra attention */
25 WX_DECLARE_OBJC_INTERFACE_HASHMAP(NSWindow
)
27 void AssociateNSWindow(WX_NSWindow cocoaNSWindow
);
28 void DisassociateNSWindow(WX_NSWindow cocoaNSWindow
);
29 virtual bool Cocoa_canBecomeMainWindow(bool &canBecome
)
31 virtual bool CocoaDelegate_windowShouldClose(void) = 0;
32 virtual void CocoaDelegate_windowWillClose(void) = 0;
33 virtual void CocoaDelegate_windowDidBecomeKey(void) { }
34 virtual void CocoaDelegate_windowDidResignKey(void) { }
35 virtual void CocoaDelegate_windowDidBecomeMain(void) { }
36 virtual void CocoaDelegate_windowDidResignMain(void) { }
37 virtual wxMenuBar
* GetAppMenuBar(wxCocoaNSWindow
*win
);
39 static struct objc_object
*sm_cocoaDelegate
;
42 #endif // _WX_COCOA_NSWINDOW_H_