Modified src/QtCore/QtChildEvent.h
from [cc67226409]
to [7edeecc781].
︙ | | |
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
|
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
|
-
-
-
-
+
+
+
+
+
-
+
|
@interface QtChildEvent: QtEvent
@property (readonly, nonatomic) QChildEvent *qChildEvent;
@property (readonly, nonatomic, getter=isAdded) bool added;
@property (readonly, nonatomic) QtObject *child;
@property (readonly, nonatomic, getter=isPolished) bool polished;
@property (readonly, nonatomic, getter=isRemoved) bool removed;
- initWithQEvent: (QEvent *)event OF_UNAVAILABLE;
- initWithQChildEvent: (QChildEvent *)qChildEvent OF_DESIGNATED_INITIALIZER;
- initWithType: (QChildEvent::Type)type
child: (QtObject *)child;
- (instancetype)initWithQEvent: (QEvent *)event OF_UNAVAILABLE;
- (instancetype)initWithQChildEvent:
(QChildEvent *)qChildEvent OF_DESIGNATED_INITIALIZER;
- (instancetype)initWithType: (QChildEvent::Type)type
child: (QtObject *)child;
@end
namespace ObjQt {
static OF_INLINE QtChildEvent *
toOF(QChildEvent *qChildEvent)
{
if (qChildEvent == NULL)
return nil;
return [[[QtChildEvent alloc]
initWithQChildEvent: qChildEvent] autorelease];
}
static OF_INLINE QChildEvent *
toQt(QtChildEvent *childEvent)
{
return [childEvent qChildEvent];
return childEvent.qChildEvent;
}
}
|
Modified src/QtCore/QtChildEvent.mm
from [ebdc9a8fdc]
to [c3305b4c88].
︙ | | |
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
|
-
+
-
+
-
-
+
+
|
#import "QtChildEvent.h"
#import "QtObject.h"
using ObjQt::toOF;
using ObjQt::toQt;
@implementation QtChildEvent
- initWithQEvent: (QEvent *)event
- (instancetype)initWithQEvent: (QEvent *)event
{
OF_INVALID_INIT_METHOD
}
- initWithQChildEvent: (QChildEvent *)event
- (instancetype)initWithQChildEvent: (QChildEvent *)event
{
return [super initWithQEvent: event];
}
- initWithType: (QChildEvent::Type)type
child: (QtObject *)child
- (instancetype)initWithType: (QChildEvent::Type)type
child: (QtObject *)child
{
try {
self = [self initWithQChildEvent:
new QChildEvent(type, toQt(child))];
[self takeOwnership];
|
︙ | | |
Modified src/QtCore/QtCoreApplication.h
from [f2a00d6135]
to [375ef06900].
︙ | | |
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
-
-
+
+
|
@interface QtCoreApplication: QtObject
@property (readonly, nonatomic) QCoreApplication *qCoreApplication;
@property (nonatomic, copy) OFString *applicationName, *applicationVersion;
@property (nonatomic, copy) OFString *organizationDomain, *organizationName;
@property (nonatomic, getter=isQuitLockEnabled) bool quitLockEnabled;
- initWithQObject: (QObject *)qObject OF_UNAVAILABLE;
- initWithQCoreApplication: (QCoreApplication *)qCoreApplication
- (instancetype)initWithQObject: (QObject *)qObject OF_UNAVAILABLE;
- (instancetype)initWithQCoreApplication: (QCoreApplication *)qCoreApplication
OF_DESIGNATED_INITIALIZER;
- (void)installNativeEventFilter: (QAbstractNativeEventFilter *)filterObject;
- (void)quit;
- (void)removeNativeEventFilter: (QAbstractNativeEventFilter *)filterObject;
- (bool)sendEvent: (QtEvent *)event
receiver: (QtObject *)receiver;
@end
|
︙ | | |
51
52
53
54
55
56
57
58
59
60
61
|
51
52
53
54
55
56
57
58
59
60
61
|
-
+
|
return [[[QtCoreApplication alloc]
initWithQCoreApplication: qCoreApplication] autorelease];
}
static OF_INLINE QCoreApplication *
toQt(QtCoreApplication *coreApplication)
{
return [coreApplication qCoreApplication];
return coreApplication.qCoreApplication;
}
}
|
Modified src/QtCore/QtCoreApplication.mm
from [efe4224b0c]
to [e01d9573b3].
︙ | | |
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
-
+
-
+
|
#import "QtEvent.h"
#import "OFString+QString.h"
using ObjQt::toOF;
using ObjQt::toQt;
@implementation QtCoreApplication
- initWithQObject: (QObject *)qObject
- (instancetype)initWithQObject: (QObject *)qObject
{
OF_INVALID_INIT_METHOD
}
- initWithQCoreApplication: (QCoreApplication *)qCoreApplication
- (instancetype)initWithQCoreApplication: (QCoreApplication *)qCoreApplication
{
return [super initWithQObject: qCoreApplication];
}
- (QCoreApplication *)qCoreApplication
{
return qobject_cast<QCoreApplication *>(_qObject);
|
︙ | | |
Modified src/QtCore/QtEvent.h
from [24149a7d9b]
to [3d675a8122].
︙ | | |
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
|
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
|
-
-
+
+
-
+
|
@property (readonly, nonatomic) QEvent *qEvent;
@property (nonatomic, getter=isAccepted) bool accepted;
@property (readonly, nonatomic, getter=isSpontaneous) bool spontaneous;
@property (readonly, nonatomic) QEvent::Type type;
+ (int)registerEventType: (int)hint;
- init OF_UNAVAILABLE;
- initWithQEvent: (QEvent *)qEvent OF_DESIGNATED_INITIALIZER;
- (instancetype)init OF_UNAVAILABLE;
- (instancetype)initWithQEvent: (QEvent *)qEvent OF_DESIGNATED_INITIALIZER;
- (void)accept;
- (void)ignore;
@end
namespace ObjQt {
static OF_INLINE QtEvent *
toOF(QEvent *qEvent)
{
if (qEvent == NULL)
return nil;
return [[[QtEvent alloc] initWithQEvent: qEvent] autorelease];
}
static OF_INLINE QEvent *
toQt(QtEvent *event)
{
return [event qEvent];
return event.qEvent;
}
}
|
Modified src/QtCore/QtEvent.mm
from [8e511e2d99]
to [f106a26f16].
︙ | | |
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
|
-
+
-
+
|
@synthesize qEvent = _qEvent;
+ (int)registerEventType: (int)hint
{
return QEvent::registerEventType(hint);
}
- init
- (instancetype)init
{
OF_INVALID_INIT_METHOD
}
- initWithQEvent: (QEvent *)qEvent
- (instancetype)initWithQEvent: (QEvent *)qEvent
{
self = [super init];
_qEvent = qEvent;
return self;
}
|
︙ | | |
Modified src/QtCore/QtObject.h
from [a05ce1afd4]
to [f647cbd434].
︙ | | |
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
-
-
+
+
|
@property (retain, nonatomic) QtObject *parent;
@property (copy, nonatomic) OFString *objectName;
@property (readonly, nonatomic) OFArray OF_GENERIC(QtObject *) *children;
@property (readonly, nonatomic)
OFArray OF_GENERIC(OFData *) *dynamicPropertyNames;
@property (readonly, nonatomic) QtThread *thread;
- init OF_UNAVAILABLE;
- initWithQObject: (QObject *)qObject OF_DESIGNATED_INITIALIZER;
- (instancetype)init OF_UNAVAILABLE;
- (instancetype)initWithQObject: (QObject *)qObject OF_DESIGNATED_INITIALIZER;
- (bool)setBlockSignals: (bool)block;
- (QMetaObject::Connection)connectSignal: (OFString *)signal
sender: (QtObject *)sender
method: (OFString *)method
type: (Qt::ConnectionType)type;
- (bool)disconnectSignal: (OFString *)signal
receiver: (QtObject *)receiver
|
︙ | | |
93
94
95
96
97
98
99
100
101
102
103
|
93
94
95
96
97
98
99
100
101
102
103
|
-
+
|
return [[[QtObject alloc] initWithQObject: qObject] autorelease];
}
static OF_INLINE QObject *
toQt(QtObject *object)
{
return [object qObject];
return object.qObject;
}
}
|
Modified src/QtCore/QtObject.mm
from [6d3b19433b]
to [9c5a288510].
︙ | | |
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
-
+
-
+
|
using ObjQt::toOF;
using ObjQt::toQt;
@implementation QtObject
@synthesize qObject = _qObject;
- init
- (instancetype)init
{
OF_INVALID_INIT_METHOD
}
- initWithQObject: (QObject *)qObject
- (instancetype)initWithQObject: (QObject *)qObject
{
self = [super init];
_qObject = qObject;
return self;
}
|
︙ | | |
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
127
128
129
130
|
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
127
128
129
130
|
-
+
-
-
+
+
-
+
|
- (QMetaObject::Connection)connectSignal: (OFString *)signal
sender: (QtObject *)sender
method: (OFString *)method
type: (Qt::ConnectionType)type
{
return _qObject->connect(toQt(sender),
[signal UTF8String], [method UTF8String], type);
signal.UTF8String, method.UTF8String, type);
}
- (bool)disconnectSignal: (OFString *)signal
receiver: (QtObject *)receiver
method: (OFString *)method
{
return _qObject->disconnect([signal UTF8String], toQt(receiver),
[method UTF8String]);
return _qObject->disconnect(signal.UTF8String, toQt(receiver),
method.UTF8String);
}
- (bool)disconnectAllSignalsForReceiver: (QtObject *)receiver
method: (OFString *)method
{
return _qObject->disconnect(toQt(receiver), [method UTF8String]);
return _qObject->disconnect(toQt(receiver), method.UTF8String);
}
- (void)dumpObjectInfo
{
_qObject->dumpObjectInfo();
}
|
︙ | | |
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
|
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
|
-
+
|
forObject: (QtObject *)watched
{
return _qObject->eventFilter(toQt(watched), toQt(event));
}
- (bool)inheritsClassWithName: (OFString *)className
{
return _qObject->inherits([className UTF8String]);
return _qObject->inherits(className.UTF8String);
}
- (void)installEventFilter: (QtObject *)filterObj
{
_qObject->installEventFilter(toQt(filterObj));
}
|
︙ | | |
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
|
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
|
-
+
-
+
|
- (void)setParent: (QtObject *)parent
{
_qObject->setParent(toQt(parent));
}
- (QVariant)propertyForName: (OFString *)name
{
return _qObject->property([name UTF8String]);
return _qObject->property(name.UTF8String);
}
- (void)removeEventFilter: (QtObject *)obj
{
_qObject->removeEventFilter(toQt(obj));
}
- (bool)setProperty: (QVariant &)value
forName: (OFString *)name
{
return _qObject->setProperty([name UTF8String], value);
return _qObject->setProperty(name.UTF8String, value);
}
- (bool)signalsBlocked
{
return _qObject->signalsBlocked();
}
|
︙ | | |
Modified src/QtCore/QtThread.h
from [e673e5e739]
to [7f1fce86f4].
︙ | | |
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
|
-
-
+
+
|
@property (readonly, nonatomic, getter=isInterruptionRequested)
bool interruptionRequested;
@property (readonly, nonatomic, getter=isRunning) bool running;
@property (readonly, nonatomic) int loopLevel;
@property (nonatomic) QThread::Priority priority;
@property (nonatomic) unsigned int stackSize;
- initWithQObject: (QObject *)qObject OF_UNAVAILABLE;
- initWithQThread: (QThread *)qThread OF_DESIGNATED_INITIALIZER;
- (instancetype)initWithQObject: (QObject *)qObject OF_UNAVAILABLE;
- (instancetype)initWithQThread: (QThread *)qThread OF_DESIGNATED_INITIALIZER;
- (void)exitWithReturnCode: (int)returnCode;
- (void)requestInterruption;
- (bool)waitForMilliseconds: (unsigned long)time;
- (void)quit;
- (void)startWithPriority: (QThread::Priority)priority;
- (void)terminate;
@end
|
︙ | | |
55
56
57
58
59
60
61
62
63
64
65
|
55
56
57
58
59
60
61
62
63
64
65
|
-
+
|
return [[[QtThread alloc] initWithQThread: qThread] autorelease];
}
static OF_INLINE QThread *
toQt(QtThread *thread)
{
return [thread qThread];
return thread.qThread;
}
}
|
Modified src/QtCore/QtThread.mm
from [fd57508770]
to [2207e4ec9f].
︙ | | |
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
|
-
+
-
+
|
*/
#import "QtThread.h"
using ObjQt::toQt;
@implementation QtThread: QtObject
- initWithQObject: (QObject *)qObject
- (instancetype)initWithQObject: (QObject *)qObject
{
OF_INVALID_INIT_METHOD
}
- initWithQThread: (QThread *)qThread
- (instancetype)initWithQThread: (QThread *)qThread
{
return [super initWithQObject: qThread];
}
- (QThread *)qThread
{
return qobject_cast<QThread *>(_qObject);
|
︙ | | |
Modified src/QtGui/QtGUIApplication.h
from [a966c37426]
to [4c1e791d6d].
︙ | | |
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
|
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
|
-
-
+
+
+
|
@property (readonly, nonatomic) OFString *platformName;
@property (readonly, nonatomic) QScreen *primaryScreen;
@property (nonatomic) bool quitsOnLastWindowClosed;
@property (nonatomic) QIcon windowIcon;
@property (readonly, nonatomic) OFString *sessionID;
@property (readonly, nonatomic) OFString *sessionKey;
- initWithQCoreApplication: (QCoreApplication *)qCoreApplication OF_UNAVAILABLE;
- initWithQGuiApplication: (QGuiApplication *)qGuiApplication
- (instancetype)initWithQCoreApplication: (QCoreApplication *)qCoreApplication
OF_UNAVAILABLE;
- (instancetype)initWithQGuiApplication: (QGuiApplication *)qGuiApplication
OF_DESIGNATED_INITIALIZER;
- (double)devicePixelRatio;
- (bool)isSavingSession;
- (bool)isSessionRestored;
@end
namespace ObjQt {
|
︙ | | |
57
58
59
60
61
62
63
64
65
66
67
|
58
59
60
61
62
63
64
65
66
67
68
|
-
+
|
return [[[QtGUIApplication alloc]
initWithQGuiApplication: qGuiApplication] autorelease];
}
static OF_INLINE QGuiApplication *
toQt(QtGUIApplication *GUIApplication)
{
return [GUIApplication qGuiApplication];
return GUIApplication.qGuiApplication;
}
}
|
Modified src/QtGui/QtGUIApplication.mm
from [69d747a94f]
to [d94fd4f320].
︙ | | |
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
-
+
-
+
|
#include <QIcon>
using ObjQt::toOF;
using ObjQt::toQt;
@implementation QtGUIApplication
- initWithQCoreApplication: (QCoreApplication *)qCoreApplication
- (instancetype)initWithQCoreApplication: (QCoreApplication *)qCoreApplication
{
OF_INVALID_INIT_METHOD
}
- initWithQGuiApplication: (QGuiApplication *)qGuiApplication
- (instancetype)initWithQGuiApplication: (QGuiApplication *)qGuiApplication
{
return [super initWithQCoreApplication: qGuiApplication];
}
- (QGuiApplication *)qGuiApplication
{
return qobject_cast<QGuiApplication *>(_qObject);
|
︙ | | |
Modified src/QtGui/QtPaintDevice.h
from [44435cb862]
to [f2a0c475c4].
︙ | | |
49
50
51
52
53
54
55
56
57
58
59
|
49
50
51
52
53
54
55
56
57
58
59
|
-
+
|
@end
namespace ObjQt {
static OF_INLINE QPaintDevice *
toQt(id <QtPaintDevice> paintDevice)
{
return [paintDevice qPaintDevice];
return paintDevice.qPaintDevice;
}
}
|
Modified src/QtGui/QtPaintDevice.mm
from [dfb9eb98ed]
to [ac42e38a1e].
︙ | | |
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
|
-
+
|
using ObjQt::toQt;
@implementation QtPaintDevice
@dynamic qObject;
- (QPaintDevice *)qPaintDevice
{
return dynamic_cast<QPaintDevice *>([self qObject]);
return dynamic_cast<QPaintDevice *>(self.qObject);
}
- (int)colorCount
{
return toQt(self)->colorCount();
}
|
︙ | | |
Modified src/QtWidgets/QtAbstractButton.h
from [37773e2710]
to [4524430429].
︙ | | |
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
|
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
|
-
-
+
+
-
+
|
@property (nonatomic, getter=isDown) bool down;
@property (nonatomic) QIcon icon;
@property (nonatomic) of_dimension_t iconSize;
@property (nonatomic) QKeySequence shortcut;
@property (nonatomic, copy) OFString *text;
@property (readonly, nonatomic) QButtonGroup *group;
- initWithQWidget: (QWidget *)qWidget OF_UNAVAILABLE;
- initWithQAbstractButton: (QAbstractButton *)qAbstractButton
- (instancetype)initWithQWidget: (QWidget *)qWidget OF_UNAVAILABLE;
- (instancetype)initWithQAbstractButton: (QAbstractButton *)qAbstractButton
OF_DESIGNATED_INITIALIZER;
@end
namespace ObjQt {
static OF_INLINE QtAbstractButton *
toOF(QAbstractButton *qAbstractButton)
{
if (qAbstractButton == NULL)
return nil;
return [[[QtAbstractButton alloc]
initWithQAbstractButton: qAbstractButton] autorelease];
}
static OF_INLINE QAbstractButton *
toQt(QtAbstractButton *abstractButton)
{
return [abstractButton qAbstractButton];
return abstractButton.qAbstractButton;
}
}
|
Modified src/QtWidgets/QtAbstractButton.mm
from [f1590706d2]
to [4e3baa2d62].
︙ | | |
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
-
+
-
+
|
#import "helpers.h"
using ObjQt::toOF;
using ObjQt::toQt;
@implementation QtAbstractButton
- initWithQWidget: (QWidget *)qWidget
- (instancetype)initWithQWidget: (QWidget *)qWidget
{
OF_INVALID_INIT_METHOD
}
- initWithQAbstractButton: (QAbstractButton *)qAbstractButton
- (instancetype)initWithQAbstractButton: (QAbstractButton *)qAbstractButton
{
return [super initWithQWidget: qAbstractButton];
}
- (QAbstractButton *)qAbstractButton
{
return qobject_cast<QAbstractButton *>(_qObject);
|
︙ | | |
Modified src/QtWidgets/QtAction.h
from [774a285c94]
to [07d907adca].
︙ | | |
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
|
-
+
-
-
+
+
|
@property (copy, nonatomic) OFString *statusTip;
@property (copy, nonatomic) OFString *text;
@property (copy, nonatomic) OFString *toolTip;
@property (nonatomic, getter=isVisible) bool visible;
@property (copy, nonatomic) OFString *whatsThis;
@property (readonly, nonatomic)
OFArray OF_GENERIC(QtWidget *) *associatedWidgets;
@property (nonatomic, setter=setSeparator:) bool isSeparator;
@property (nonatomic, setter=setSeparator:) bool isSeparator;
@property (readonly, nonatomic) QtWidget *parentWidget;
- initWithQObject: (QObject *)qObject OF_UNAVAILABLE;
- initWithQAction: (QAction *)qAction OF_DESIGNATED_INITIALIZER;
- (instancetype)initWithQObject: (QObject *)qObject OF_UNAVAILABLE;
- (instancetype)initWithQAction: (QAction *)qAction OF_DESIGNATED_INITIALIZER;
- (QActionGroup *)actionGroup;
- (void)activate: (QAction::ActionEvent)event;
- (QList<QGraphicsWidget *>)associatedGraphicsWidgets;
- (QVariant)data;
- (QMenu *)menu;
- (void)setActionGroup: (QActionGroup *)group;
- (void)setData: (const QVariant &)data;
|
︙ | | |
75
76
77
78
79
80
81
82
83
84
85
|
75
76
77
78
79
80
81
82
83
84
85
|
-
+
|
return [[[QtAction alloc] initWithQAction: qAction] autorelease];
}
static OF_INLINE QAction *
toQt(QtAction *action)
{
return [action qAction];
return action.qAction;
}
}
|
Modified src/QtWidgets/QtAction.mm
from [7055d441a2]
to [521c089e12].
︙ | | |
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
|
-
+
-
+
|
#import "QtWidget.h"
#import "OFString+QString.h"
using ObjQt::toOF;
using ObjQt::toQt;
@implementation QtAction
- initWithQObject: (QObject *)qObject
- (instancetype)initWithQObject: (QObject *)qObject
{
OF_INVALID_INIT_METHOD
}
- initWithQAction: (QAction *)qAction
- (instancetype)initWithQAction: (QAction *)qAction
{
return [super initWithQObject: qAction];
}
- (QAction *)qAction
{
return qobject_cast<QAction *>(_qObject);
|
︙ | | |
Modified src/QtWidgets/QtApplication.h
from [37ef3d484f]
to [40e6864610].
︙ | | |
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
|
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
|
-
-
+
+
+
+
-
+
|
@property (nonatomic) of_dimension_t globalStrut;
@property (nonatomic) int keyboardInputInterval;
@property (nonatomic) int startDragDistance;
@property (nonatomic) int startDragTime;
@property (nonatomic, copy) OFString *styleSheet;
@property (nonatomic) int wheelScrollLines;
- initWithQGuiApplication: (QGuiApplication *)qGuiApplication OF_UNAVAILABLE;
- initWithQApplication: (QApplication *)qApplication OF_DESIGNATED_INITIALIZER;
- (instancetype)initWithQGuiApplication: (QGuiApplication *)qGuiApplication
OF_UNAVAILABLE;
- (instancetype)initWithQApplication: (QApplication *)qApplication
OF_DESIGNATED_INITIALIZER;
- (void)aboutQt;
- (void)closeAllWindows;
@end
namespace ObjQt {
static OF_INLINE QtApplication *
toOF(QApplication *qApplication)
{
if (qApplication == NULL)
return nil;
return [[[QtApplication alloc]
initWithQApplication: qApplication] autorelease];
}
static OF_INLINE QApplication *
toQt(QtApplication *application)
{
return [application qApplication];
return application.qApplication;
}
}
|
Modified src/QtWidgets/QtApplication.mm
from [791c79a84e]
to [18996e8953].
︙ | | |
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
|
-
+
-
+
|
#import "helpers.h"
using ObjQt::toOF;
using ObjQt::toQt;
@implementation QtApplication
- initWithQGuiApplication: (QGuiApplication *)qGuiApplication
- (instancetype)initWithQGuiApplication: (QGuiApplication *)qGuiApplication
{
OF_INVALID_INIT_METHOD
}
- initWithQApplication: (QApplication *)qApplication
- (instancetype)initWithQApplication: (QApplication *)qApplication
{
return [super initWithQGuiApplication: qApplication];
}
- (QApplication *)qApplication
{
return qobject_cast<QApplication *>(_qObject);
|
︙ | | |
Modified src/QtWidgets/QtGraphicsWidget.h
from [a89fbd8595]
to [cab64f2316].
︙ | | |
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
|
-
-
+
+
|
@property (copy, nonatomic) OFString *windowTitle;
@property (readonly, nonatomic) OFArray OF_GENERIC(QtAction *) *actions;
@property (readonly, nonatomic) bool isActiveWindow;
@property (nonatomic) QStyle *style;
@property (readonly, nonatomic) of_rectangle_t windowFrameGeometry;
@property (readonly, nonatomic) of_rectangle_t windowFrameRect;
- initWithQObject: (QObject *)qObject OF_UNAVAILABLE;
- initWithQGraphicsWidget: (QGraphicsWidget *)qGraphicsWidget
- (instancetype)initWithQObject: (QObject *)qObject OF_UNAVAILABLE;
- (instancetype)initWithQGraphicsWidget: (QGraphicsWidget *)qGraphicsWidget
OF_DESIGNATED_INITIALIZER;
- (void)addAction: (QtAction *)action;
- (void)addActions: (OFArray OF_GENERIC(QtAction *) *)actions;
- (void)adjustSize;
- (QtGraphicsWidget *)focusWidget;
- (void)getWindowFrameMarginsWithLeft: (qreal *)left
top: (qreal *)top
|
︙ | | |
103
104
105
106
107
108
109
110
111
112
113
|
103
104
105
106
107
108
109
110
111
112
113
|
-
+
|
return [[[QtGraphicsWidget alloc]
initWithQGraphicsWidget: qGraphicsWidget] autorelease];
}
static OF_INLINE QGraphicsWidget *
toQt(QtGraphicsWidget *graphicsWidget)
{
return [graphicsWidget qGraphicsWidget];
return graphicsWidget.qGraphicsWidget;
}
}
|
Modified src/QtWidgets/QtGraphicsWidget.mm
from [ff29f683eb]
to [1af5bd7cf4].
︙ | | |
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
|
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
|
-
+
-
+
-
+
|
using ObjQt::toQt;
@implementation QtGraphicsObject
@end
@implementation QtGraphicsWidget
- initWithQObject: (QObject *)qObject
- (instancetype)initWithQObject: (QObject *)qObject
{
OF_INVALID_INIT_METHOD
}
- initWithQGraphicsWidget: (QGraphicsWidget *)qGraphicsWidget
- (instancetype)initWithQGraphicsWidget: (QGraphicsWidget *)qGraphicsWidget
{
return [super initWithQObject: qGraphicsWidget];
}
- (QGraphicsWidget *)qGraphicsWidget
{
return dynamic_cast<QGraphicsWidget *>([self qObject]);
return dynamic_cast<QGraphicsWidget *>(self.qObject);
}
- (bool)autoFillBackground
{
return toQt(self)->autoFillBackground();
}
|
︙ | | |
Modified src/QtWidgets/QtPushButton.h
from [0c750e4bdb]
to [9d343457e1].
︙ | | |
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
|
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
|
-
-
-
-
-
+
+
+
+
+
+
+
-
+
|
@interface QtPushButton: QtAbstractButton
@property (readonly, nonatomic) QPushButton *qPushButton;
@property (nonatomic) QMenu *menu;
@property (nonatomic) bool autoDefault;
@property (nonatomic, getter=isDefault, setter=setDefault:) bool default_;
@property (nonatomic, getter=isFlat) bool flat;
- initWithQAbstractButton: (QAbstractButton *)qAbstractButton OF_UNAVAILABLE;
- initWithQPushButton: (QPushButton *)qPushButton OF_DESIGNATED_INITIALIZER;
- initWithText: (OFString *)text;
- initWithIcon: (QIcon)icon
text: (OFString *)text;
- (instancetype)initWithQAbstractButton: (QAbstractButton *)qAbstractButton
OF_UNAVAILABLE;
- (instancetype)initWithQPushButton: (QPushButton *)qPushButton
OF_DESIGNATED_INITIALIZER;
- (instancetype)initWithText: (OFString *)text;
- (instancetype)initWithIcon: (QIcon)icon
text: (OFString *)text;
@end
namespace ObjQt {
static OF_INLINE QtPushButton *
toOF(QPushButton *qPushButton)
{
if (qPushButton == NULL)
return nil;
return [[[QtPushButton alloc]
initWithQPushButton: qPushButton] autorelease];
}
static OF_INLINE QPushButton *
toQt(QtPushButton *pushButton)
{
return [pushButton qPushButton];
return pushButton.qPushButton;
}
}
|
Modified src/QtWidgets/QtPushButton.mm
from [8cd49ef499]
to [73cdca55fb].
︙ | | |
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
|
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
|
-
+
-
+
-
+
-
-
+
+
|
#import "helpers.h"
using ObjQt::toOF;
using ObjQt::toQt;
@implementation QtPushButton
- initWithQAbstractButton: (QAbstractButton *)qAbstractButton
- (instancetype)initWithQAbstractButton: (QAbstractButton *)qAbstractButton
{
OF_INVALID_INIT_METHOD
}
- initWithQPushButton: (QPushButton *)qPushButton
- (instancetype)initWithQPushButton: (QPushButton *)qPushButton
{
return [super initWithQAbstractButton: qPushButton];
}
- initWithText: (OFString *)text
- (instancetype)initWithText: (OFString *)text
{
try {
self = [self initWithQPushButton:
new QPushButton(toQt(text))];
[self takeOwnership];
return self;
} catch (const std::bad_alloc &e) {
self = [self initWithQPushButton: NULL];
[self release];
throw;
}
}
- initWithIcon: (QIcon)icon
text: (OFString *)text
- (instancetype)initWithIcon: (QIcon)icon
text: (OFString *)text
{
try {
self = [self initWithQPushButton:
new QPushButton(icon, toQt(text))];
[self takeOwnership];
|
︙ | | |
Modified src/QtWidgets/QtWidget.h
from [cadc7c9183]
to [c24969fde7].
︙ | | |
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
|
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
|
-
-
+
+
|
@property (readonly, nonatomic) QtWidget *nativeParentWidget;
@property (readonly, nonatomic) QtWidget *nextInFocusChain;
@property (readonly, nonatomic) QtWidget *parentWidget;
@property (readonly, nonatomic) QtWidget *previousInFocusChain;
@property (readonly, nonatomic) QtWidget *window;
@property (readonly, nonatomic) OFString *windowRole;
- initWithQObject: (QObject *)qObject OF_UNAVAILABLE;
- initWithQWidget: (QWidget *)qWidget OF_DESIGNATED_INITIALIZER;
- (instancetype)initWithQObject: (QObject *)qObject OF_UNAVAILABLE;
- (instancetype)initWithQWidget: (QWidget *)qWidget OF_DESIGNATED_INITIALIZER;
- (void)activateWindow;
- (void)addAction: (QtAction *)action;
- (void)addActions: (OFArray OF_GENERIC(QtAction *) *)actions;
- (void)adjustSize;
- (QPalette::ColorRole)backgroundRole;
- (QBackingStore *)backingStore;
- (QtWidget *)childAt: (of_point_t)point;
|
︙ | | |
234
235
236
237
238
239
240
241
242
243
244
|
234
235
236
237
238
239
240
241
242
243
244
|
-
+
|
return [[[QtWidget alloc] initWithQWidget: qWidget] autorelease];
}
static OF_INLINE QWidget *
toQt(QtWidget *widget)
{
return [widget qWidget];
return widget.qWidget;
}
}
|
Modified src/QtWidgets/QtWidget.mm
from [e7bf98bf6f]
to [dd7b1dee96].
︙ | | |
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
|
-
+
-
+
|
@implementation QtWidget
+ (void)initialize
{
if (self == [QtWidget class])
[self inheritMethodsFromClass: [QtPaintDevice class]];
}
- initWithQObject: (QObject *)qObject
- (instancetype)initWithQObject: (QObject *)qObject
{
OF_INVALID_INIT_METHOD
}
- initWithQWidget: (QWidget *)qWidget
- (instancetype)initWithQWidget: (QWidget *)qWidget
{
return [super initWithQObject: qWidget];
}
- (QWidget *)qWidget
{
return qobject_cast<QWidget *>(_qObject);
|
︙ | | |
Modified src/common/OFColor+QColor.h
from [034bea841e]
to [0d62d3f80f].
︙ | | |
21
22
23
24
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
|
21
22
23
24
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
|
+
+
-
-
+
|
*/
#import <ObjFW/ObjFW.h>
#include <QColor>
@interface OFColor (QColor)
@property (readonly, nonatomic) QColor qColor;
+ (instancetype)colorWithQColor: (const QColor &)qColor;
- (instancetype)initWithQColor: (const QColor &)qColor;
- (QColor)qColor;
@end
namespace ObjQt {
static OF_INLINE OFColor *
toOF(const QColor &qColor)
{
if (!qColor.isValid())
return nil;
return [OFColor colorWithQColor: qColor];
}
static OF_INLINE QColor
toQt(OFColor *color)
{
if (color == nil)
return QColor();
return [color qColor];
return color.qColor;
}
}
|
Modified src/common/OFData+QByteArray.h
from [1450dd7a8e]
to [f6d6179376].
︙ | | |
21
22
23
24
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
|
21
22
23
24
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
|
+
+
-
-
+
|
*/
#import <ObjFW/ObjFW.h>
#include <QByteArray>
@interface OFData (QByteArray)
@property (readonly, nonatomic) QByteArray qByteArray;
+ (instancetype)dataWithQByteArray: (const QByteArray &)qByteArray;
- (instancetype)initWithQByteArray: (const QByteArray &)qByteArray;
- (QByteArray)qByteArray;
@end
namespace ObjQt {
static OF_INLINE OFData *
toOF(const QByteArray &qByteArray)
{
if (qByteArray.isNull())
return nil;
return [OFData dataWithQByteArray: qByteArray];
}
static OF_INLINE QByteArray
toQt(OFData *data)
{
if (data == nil)
return QByteArray();
return [data qByteArray];
return data.qByteArray;
}
}
|
Modified src/common/OFData+QByteArray.mm
from [1893548556]
to [012a13bab1].
︙ | | |
32
33
34
35
36
37
38
39
40
41
42
|
32
33
34
35
36
37
38
39
40
41
|
-
+
-
|
{
return [self initWithItems: qByteArray.data()
count: qByteArray.count()];
}
- (QByteArray)qByteArray
{
return QByteArray((const char *)[self items],
return QByteArray((const char *)self.items, self.count * self.itemSize);
[self count] * [self itemSize]);
}
@end
|
Modified src/common/OFString+QString.h
from [7969d74721]
to [6cfadd843f].
︙ | | |
21
22
23
24
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
|
21
22
23
24
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
|
+
+
-
-
+
|
*/
#import <ObjFW/ObjFW.h>
#include <QString>
@interface OFString (QString)
@property (readonly, nonatomic) QString qString;
+ (instancetype)stringWithQString: (const QString &)qString;
- (instancetype)initWithQString: (const QString &)qString;
- (QString)qString;
@end
namespace ObjQt {
static OF_INLINE OFString *
toOF(const QString &qString)
{
if (qString.isNull())
return nil;
return [OFString stringWithQString: qString];
}
static OF_INLINE QString
toQt(OFString *string)
{
if (string == nil)
return QString();
return [string qString];
return string.qString;
}
}
|
Modified src/common/OFString+QString.mm
from [d6be9ba96e]
to [6f7675c9c9].
︙ | | |
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
39
40
41
42
43
44
45
46
47
48
49
50
51
52
|
-
+
|
- (QString)qString
{
static_assert(sizeof(char16_t) == sizeof(QChar),
"char16_t and QChar have a different size!");
void *pool = objc_autoreleasePoolPush();
QString ret = QString((QChar *)[self UTF16String]);
QString ret = QString((QChar *)self.UTF16String);
objc_autoreleasePoolPop(pool);
return ret;
}
@end
|