Differences From Artifact [f0fdef84ef]:
- File
src/QtGui/QtGUIApplication.mm
— part of check-in
[baf52ea3b1]
at
2017-04-17 23:25:45
on branch trunk
— Add a proper build system
Also lowers the minimum required Qt version to 5.5. (user: js, size: 3121) [annotate] [blame] [check-ins using]
To Artifact [69d747a94f]:
- File src/QtGui/QtGUIApplication.mm — part of check-in [860515ac5a] at 2017-05-08 00:11:18 on branch trunk — Update to recent ObjFW changes (user: js, size: 3133) [annotate] [blame] [check-ins using]
︙ | ︙ | |||
25 26 27 28 29 30 31 | #include <QIcon> using ObjQt::toOF; using ObjQt::toQt; @implementation QtGUIApplication | | | | | | | | | | 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 | #include <QIcon> using ObjQt::toOF; using ObjQt::toQt; @implementation QtGUIApplication - initWithQCoreApplication: (QCoreApplication *)qCoreApplication { OF_INVALID_INIT_METHOD } - initWithQGuiApplication: (QGuiApplication *)qGuiApplication { return [super initWithQCoreApplication: qGuiApplication]; } - (QGuiApplication *)qGuiApplication { return qobject_cast<QGuiApplication *>(_qObject); } - (OFString *)applicationDisplayName { return toOF(toQt(self)->applicationDisplayName()); } - (void)setApplicationDisplayName: (OFString *)applicationDisplayName { toQt(self)->setApplicationDisplayName(toQt(applicationDisplayName)); } #if QT_VERSION >= QT_VERSION_CHECK(5, 7, 0) - (OFString *)desktopFileName { return toOF(toQt(self)->desktopFileName()); } - (void)setDesktopFileName: (OFString *)desktopFileName { toQt(self)->setDesktopFileName(toQt(desktopFileName)); } #endif - (double)devicePixelRatio { |
︙ | ︙ | |||
87 88 89 90 91 92 93 | } - (void)setLayoutDirection: (Qt::LayoutDirection)layoutDirection { toQt(self)->setLayoutDirection(layoutDirection); } | | | | | | 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 | } - (void)setLayoutDirection: (Qt::LayoutDirection)layoutDirection { toQt(self)->setLayoutDirection(layoutDirection); } - (OFString *)platformName { return toOF(toQt(self)->platformName()); } - (QScreen *)primaryScreen { return toQt(self)->primaryScreen(); } - (bool)quitsOnLastWindowClosed { return toQt(self)->quitOnLastWindowClosed(); } - (void)setQuitsOnLastWindowClosed: (bool)quitsOnLastWindowClosed { toQt(self)->setQuitOnLastWindowClosed(quitsOnLastWindowClosed); } - (OFString *)sessionID { return toOF(toQt(self)->sessionId()); } - (OFString *)sessionKey { return toOF(toQt(self)->sessionKey()); } - (QIcon)windowIcon { return toQt(self)->windowIcon(); |
︙ | ︙ |