diff options
author | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2017-06-22 18:44:52 +0200 |
---|---|---|
committer | Tor Arne Vestbø <tor.arne.vestbo@qt.io> | 2017-06-27 21:56:57 +0000 |
commit | b619a9eada57451b30f8fde4b35c3143b0fdb715 (patch) | |
tree | 3401afb2bc966530897653cd16d344542dad9e64 /src/plugins/platforms/cocoa/qnswindow.h | |
parent | 4ac47689fad1e7c0b169cb5959a12f9d53aee625 (diff) |
macOS: Make QCocoaNSWindow header file slightly more readable
Change-Id: I09ac42af476feb1d561a77f68999a2754a2e252e
Reviewed-by: Tor Arne Vestbø <tor.arne.vestbo@qt.io>
Diffstat (limited to 'src/plugins/platforms/cocoa/qnswindow.h')
-rw-r--r-- | src/plugins/platforms/cocoa/qnswindow.h | 32 |
1 files changed, 14 insertions, 18 deletions
diff --git a/src/plugins/platforms/cocoa/qnswindow.h b/src/plugins/platforms/cocoa/qnswindow.h index 580564aeee..c5f6403478 100644 --- a/src/plugins/platforms/cocoa/qnswindow.h +++ b/src/plugins/platforms/cocoa/qnswindow.h @@ -47,17 +47,23 @@ #include <AppKit/AppKit.h> QT_FORWARD_DECLARE_CLASS(QCocoaWindow) +Q_FORWARD_DECLARE_OBJC_CLASS(QT_MANGLE_NAMESPACE(QNSWindowHelper)); + +// ------------------------------------------------------------------------- @interface NSWindow (FullScreenProperty) @property(readonly) BOOL qt_fullScreen; @end -@class QT_MANGLE_NAMESPACE(QNSWindowHelper); +// ------------------------------------------------------------------------- @protocol QNSWindowProtocol @property (nonatomic, readonly) QT_MANGLE_NAMESPACE(QNSWindowHelper) *helper; +- (id)initWithContentRect:(NSRect)contentRect screen:(NSScreen*)screen + styleMask:(NSUInteger)windowStyle qPlatformWindow:(QCocoaWindow *)qpw; + - (void)superSendEvent:(NSEvent *)theEvent; - (void)closeAndRelease; @@ -65,6 +71,8 @@ QT_FORWARD_DECLARE_CLASS(QCocoaWindow) typedef NSWindow<QNSWindowProtocol> QCocoaNSWindow; +// ------------------------------------------------------------------------- + @interface QT_MANGLE_NAMESPACE(QNSWindowHelper) : NSObject { QCocoaNSWindow *_window; @@ -87,38 +95,26 @@ typedef NSWindow<QNSWindowProtocol> QCocoaNSWindow; QT_NAMESPACE_ALIAS_OBJC_CLASS(QNSWindowHelper); +// ------------------------------------------------------------------------- + @interface QT_MANGLE_NAMESPACE(QNSWindow) : NSWindow<QNSWindowProtocol> { QNSWindowHelper *_helper; } - -@property (nonatomic, readonly) QNSWindowHelper *helper; - -- (id)initWithContentRect:(NSRect)contentRect - screen:(NSScreen*)screen - styleMask:(NSUInteger)windowStyle - qPlatformWindow:(QCocoaWindow *)qpw; - @end QT_NAMESPACE_ALIAS_OBJC_CLASS(QNSWindow); +// ------------------------------------------------------------------------- + @interface QT_MANGLE_NAMESPACE(QNSPanel) : NSPanel<QNSWindowProtocol> { QNSWindowHelper *_helper; } - -@property (nonatomic, readonly) QNSWindowHelper *helper; - -- (id)initWithContentRect:(NSRect)contentRect - screen:(NSScreen*)screen - styleMask:(NSUInteger)windowStyle - qPlatformWindow:(QCocoaWindow *)qpw; - @end QT_NAMESPACE_ALIAS_OBJC_CLASS(QNSPanel); -@class QT_MANGLE_NAMESPACE(QNSWindowDelegate); +// ------------------------------------------------------------------------- #endif // QNSWINDOW_H |