77 #ifdef QT_MAC_USE_COCOA 78 #include <private/qcocoaapplication_mac_p.h> 79 #include <private/qcocoaapplicationdelegate_mac_p.h> 80 #include <private/qt_cocoa_helpers_mac_p.h> 81 #include <private/qcocoaintrospection_p.h> 89 [[QT_MANGLE_NAMESPACE(QCocoaApplicationDelegate) sharedDelegate] setDockMenu:newMenu];
94 return [[QT_MANGLE_NAMESPACE(QCocoaApplicationDelegate) sharedDelegate] qAppPrivate];
99 return [[QT_MANGLE_NAMESPACE(QCocoaApplicationDelegate) sharedDelegate] menuLoader];
106 return NSFontPanelFaceModeMask
107 | NSFontPanelSizeModeMask
108 | NSFontPanelCollectionModeMask
109 | NSFontPanelUnderlineEffectModeMask
110 | NSFontPanelStrikethroughEffectModeMask;
119 QCocoaPostMessageArgs *args =
reinterpret_cast<QCocoaPostMessageArgs *
>(lower | (upper << 32));
122 id a1 = ([args->arg1 isKindOfClass:[NSNumber class]]) ? (
id)[args->arg1 intValue] : args->arg1;
123 id a2 = ([args->arg2 isKindOfClass:[NSNumber class]]) ? (
id)[args->arg2 intValue] : args->arg2;
124 switch (args->argCount) {
126 [args->target performSelector:args->selector];
129 [args->target performSelector:args->selector withObject:a1];
132 [args->target performSelector:args->selector withObject:a1 withObject:a2];
144 if (
qApp->macEventFilter(0, reinterpret_cast<EventRef>(event)))
147 if ([event
type] == NSApplicationDefined) {
148 switch ([event subtype]) {
150 [NSApp QT_MANGLE_NAMESPACE(qt_sendPostedMessage):event];
161 @implementation QT_MANGLE_NAMESPACE(QNSApplication)
178 [
self QT_MANGLE_NAMESPACE(qt_sendEvent_original):event];
181 - (void)sendEvent:(NSEvent *)event
186 [
super sendEvent:event];
189 - (void)qtDispatcherToQAction:(
id)sender
197 [[NSApp QT_MANGLE_NAMESPACE(qt_qcocoamenuLoader)] qtDispatcherToQAction:sender];
204 void qt_redirectNSApplicationSendEvent()
217 [NSApplication
class],
218 @selector(sendEvent:),
224 void qt_resetNSApplicationSendEvent()
227 @selector(sendEvent:),
#define QT_END_NAMESPACE
This macro expands to.
#define QT_BEGIN_NAMESPACE
This macro expands to.
void qt_cocoa_change_implementation(Class baseClass, SEL originalSel, Class proxyClass, SEL replacementSel, SEL backupSel)
void qt_cocoa_change_back_implementation(Class baseClass, SEL originalSel, SEL backupSel)
#define QT_MANGLE_NAMESPACE(name)
#define QT_USE_NAMESPACE
This macro expands to using QT_NAMESPACE if QT_NAMESPACE is defined and nothing otherwise.
#define Q_UNUSED(x)
Indicates to the compiler that the parameter with the specified name is not used in the body of a fun...