diff options
author | Morten Johan Sorvig <morten.sorvig@nokia.com> | 2012-06-08 12:55:55 +0200 |
---|---|---|
committer | Qt by Nokia <qt-info@nokia.com> | 2012-06-11 11:21:37 +0200 |
commit | 4e2199617c51e8980f246b7ce436a4ff4a1a09ca (patch) | |
tree | dfd5f464c4c5a67ada127c29a29cc2fb4729d549 /src/plugins/platforms/cocoa | |
parent | 69f0782c0975d34c94d45e8162dfc77275e0b21d (diff) |
Cocoa: Remove QtWidgets dependencies.
Make the file/color dialog helpers use QCoreApplication::
translate("QDialogButtonBox", text) instead of
QDialogButtonBox::tr(text)
Change-Id: I7ee4c32f8f8b9cd002836e24b962ef1c0f2e0737
Reviewed-by: Kent Hansen <kent.hansen@nokia.com>
Reviewed-by: Bradley T. Hughes <bradley.hughes@nokia.com>
Diffstat (limited to 'src/plugins/platforms/cocoa')
-rw-r--r-- | src/plugins/platforms/cocoa/qcocoacolordialoghelper.mm | 4 | ||||
-rw-r--r-- | src/plugins/platforms/cocoa/qcocoafontdialoghelper.mm | 4 |
2 files changed, 2 insertions, 6 deletions
diff --git a/src/plugins/platforms/cocoa/qcocoacolordialoghelper.mm b/src/plugins/platforms/cocoa/qcocoacolordialoghelper.mm index d617d1d210..44b022cfb2 100644 --- a/src/plugins/platforms/cocoa/qcocoacolordialoghelper.mm +++ b/src/plugins/platforms/cocoa/qcocoacolordialoghelper.mm @@ -45,8 +45,6 @@ #include <QtCore/qdebug.h> #include <QtCore/qtimer.h> -#include <QtWidgets/qdialogbuttonbox.h> -#include <QtWidgets/qcolordialog.h> #include "qcocoahelpers.h" @@ -61,7 +59,7 @@ static NSButton *macCreateButton(const char *text, NSView *superview) NSButton *button = [[NSButton alloc] initWithFrame:buttonFrameRect]; [button setButtonType:NSMomentaryLightButton]; [button setBezelStyle:NSRoundedBezelStyle]; - [button setTitle:(NSString*)(CFStringRef)QCFString(QDialogButtonBox::tr(text) + [button setTitle:(NSString*)(CFStringRef)QCFString(QCoreApplication::translate("QDialogButtonBox", text) .remove(QLatin1Char('&')))]; [[button cell] setFont:[NSFont systemFontOfSize: [NSFont systemFontSizeForControlSize:NSRegularControlSize]]]; diff --git a/src/plugins/platforms/cocoa/qcocoafontdialoghelper.mm b/src/plugins/platforms/cocoa/qcocoafontdialoghelper.mm index 088f6265ca..141e0db245 100644 --- a/src/plugins/platforms/cocoa/qcocoafontdialoghelper.mm +++ b/src/plugins/platforms/cocoa/qcocoafontdialoghelper.mm @@ -45,8 +45,6 @@ #include <QtCore/qtimer.h> #include <QtGui/qfontdatabase.h> -#include <QtWidgets/qdialogbuttonbox.h> -#include <QtWidgets/qfontdialog.h> #include <private/qfont_p.h> #include <private/qfontengine_p.h> @@ -81,7 +79,7 @@ static NSButton *macCreateButton(const char *text, NSView *superview) NSButton *button = [[NSButton alloc] initWithFrame:buttonFrameRect]; [button setButtonType:NSMomentaryLightButton]; [button setBezelStyle:NSRoundedBezelStyle]; - [button setTitle:(NSString*)(CFStringRef)QCFString(QDialogButtonBox::tr(text) + [button setTitle:(NSString*)(CFStringRef)QCFString(QCoreApplication::translate("QDialogButtonBox", text) .remove(QLatin1Char('&')))]; [[button cell] setFont:[NSFont systemFontOfSize: [NSFont systemFontSizeForControlSize:NSRegularControlSize]]]; |