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>
This commit is contained in:
parent
69f0782c09
commit
4e2199617c
@ -45,8 +45,6 @@
|
|||||||
|
|
||||||
#include <QtCore/qdebug.h>
|
#include <QtCore/qdebug.h>
|
||||||
#include <QtCore/qtimer.h>
|
#include <QtCore/qtimer.h>
|
||||||
#include <QtWidgets/qdialogbuttonbox.h>
|
|
||||||
#include <QtWidgets/qcolordialog.h>
|
|
||||||
|
|
||||||
#include "qcocoahelpers.h"
|
#include "qcocoahelpers.h"
|
||||||
|
|
||||||
@ -61,7 +59,7 @@ static NSButton *macCreateButton(const char *text, NSView *superview)
|
|||||||
NSButton *button = [[NSButton alloc] initWithFrame:buttonFrameRect];
|
NSButton *button = [[NSButton alloc] initWithFrame:buttonFrameRect];
|
||||||
[button setButtonType:NSMomentaryLightButton];
|
[button setButtonType:NSMomentaryLightButton];
|
||||||
[button setBezelStyle:NSRoundedBezelStyle];
|
[button setBezelStyle:NSRoundedBezelStyle];
|
||||||
[button setTitle:(NSString*)(CFStringRef)QCFString(QDialogButtonBox::tr(text)
|
[button setTitle:(NSString*)(CFStringRef)QCFString(QCoreApplication::translate("QDialogButtonBox", text)
|
||||||
.remove(QLatin1Char('&')))];
|
.remove(QLatin1Char('&')))];
|
||||||
[[button cell] setFont:[NSFont systemFontOfSize:
|
[[button cell] setFont:[NSFont systemFontOfSize:
|
||||||
[NSFont systemFontSizeForControlSize:NSRegularControlSize]]];
|
[NSFont systemFontSizeForControlSize:NSRegularControlSize]]];
|
||||||
|
@ -45,8 +45,6 @@
|
|||||||
|
|
||||||
#include <QtCore/qtimer.h>
|
#include <QtCore/qtimer.h>
|
||||||
#include <QtGui/qfontdatabase.h>
|
#include <QtGui/qfontdatabase.h>
|
||||||
#include <QtWidgets/qdialogbuttonbox.h>
|
|
||||||
#include <QtWidgets/qfontdialog.h>
|
|
||||||
|
|
||||||
#include <private/qfont_p.h>
|
#include <private/qfont_p.h>
|
||||||
#include <private/qfontengine_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];
|
NSButton *button = [[NSButton alloc] initWithFrame:buttonFrameRect];
|
||||||
[button setButtonType:NSMomentaryLightButton];
|
[button setButtonType:NSMomentaryLightButton];
|
||||||
[button setBezelStyle:NSRoundedBezelStyle];
|
[button setBezelStyle:NSRoundedBezelStyle];
|
||||||
[button setTitle:(NSString*)(CFStringRef)QCFString(QDialogButtonBox::tr(text)
|
[button setTitle:(NSString*)(CFStringRef)QCFString(QCoreApplication::translate("QDialogButtonBox", text)
|
||||||
.remove(QLatin1Char('&')))];
|
.remove(QLatin1Char('&')))];
|
||||||
[[button cell] setFont:[NSFont systemFontOfSize:
|
[[button cell] setFont:[NSFont systemFontOfSize:
|
||||||
[NSFont systemFontSizeForControlSize:NSRegularControlSize]]];
|
[NSFont systemFontSizeForControlSize:NSRegularControlSize]]];
|
||||||
|
Loading…
Reference in New Issue
Block a user