summaryrefslogtreecommitdiffstats
path: root/src/gui/dialogs
diff options
context:
space:
mode:
authorNorwegian Rock Cat <qt-info@nokia.com>2009-06-23 12:42:32 (GMT)
committerNorwegian Rock Cat <qt-info@nokia.com>2009-06-23 12:44:08 (GMT)
commitf65ed7b51a573dd8429feecc19c7abe8a0a36114 (patch)
tree5ce70bc3ca67573b4a3b07c13e1a8a8be520f4bd /src/gui/dialogs
parent3464a05a94c4e638d91b2151d6aad70f78ea3087 (diff)
downloadQt-f65ed7b51a573dd8429feecc19c7abe8a0a36114.zip
Qt-f65ed7b51a573dd8429feecc19c7abe8a0a36114.tar.gz
Qt-f65ed7b51a573dd8429feecc19c7abe8a0a36114.tar.bz2
Remove some warnings in the Cocoa build.
After discussing with some of the Objective-C people I have finally got a fair number of the warnings to disappear in both 10.5 and 10.6. I also took the opportunity to remove a bunch of other warnings. Reviewed by: Morten Sørvig
Diffstat (limited to 'src/gui/dialogs')
-rw-r--r--src/gui/dialogs/qcolordialog_mac.mm12
-rw-r--r--src/gui/dialogs/qfontdialog_mac.mm4
2 files changed, 12 insertions, 4 deletions
diff --git a/src/gui/dialogs/qcolordialog_mac.mm b/src/gui/dialogs/qcolordialog_mac.mm
index c5cfcc0..06120da 100644
--- a/src/gui/dialogs/qcolordialog_mac.mm
+++ b/src/gui/dialogs/qcolordialog_mac.mm
@@ -54,11 +54,19 @@
typedef float CGFloat; // Should only not be defined on 32-bit platforms
#endif
+
+#if MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_5
+@protocol NSWindowDelegate <NSObject>
+- (void)windowDidResize:(NSNotification *)notification;
+- (BOOL)windowShouldClose:(id)window;
+@end
+#endif
+
QT_USE_NAMESPACE
@class QCocoaColorPanelDelegate;
-@interface QCocoaColorPanelDelegate : NSObject {
+@interface QCocoaColorPanelDelegate : NSObject<NSWindowDelegate> {
NSColorPanel *mColorPanel;
NSView *mStolenContentView;
NSButton *mOkButton;
@@ -74,8 +82,6 @@ QT_USE_NAMESPACE
okButton:(NSButton *)okButton
cancelButton:(NSButton *)cancelButton
priv:(QColorDialogPrivate *)priv;
-- (BOOL)windowShouldClose:(id)window;
-- (void)windowDidResize:(NSNotification *)notification;
- (void)colorChanged:(NSNotification *)notification;
- (void)relayout;
- (void)onOkClicked;
diff --git a/src/gui/dialogs/qfontdialog_mac.mm b/src/gui/dialogs/qfontdialog_mac.mm
index e7d2f43..3dc3c00 100644
--- a/src/gui/dialogs/qfontdialog_mac.mm
+++ b/src/gui/dialogs/qfontdialog_mac.mm
@@ -78,7 +78,9 @@ const int StyleMask = NSTitledWindowMask | NSClosableWindowMask | NSResizableWin
#if MAC_OS_X_VERSION_MAX_ALLOWED <= MAC_OS_X_VERSION_10_5
-@protocol NSWindowDelegate <NSObject> @end
+@protocol NSWindowDelegate <NSObject>
+- (NSSize)windowWillResize:(NSWindow *)window toSize:(NSSize)proposedFrameSize;
+@end
#endif