src/gui/util/qsystemtrayicon_mac.mm
branchRCL_3
changeset 7 3f74d0d4af4c
parent 5 d3bac044e0f0
--- a/src/gui/util/qsystemtrayicon_mac.mm	Mon Mar 15 12:43:09 2010 +0200
+++ b/src/gui/util/qsystemtrayicon_mac.mm	Thu Apr 08 14:19:33 2010 +0300
@@ -530,7 +530,11 @@
             [item setToolTip:(NSString*)QCFString::toCFStringRef(action->toolTip())];
             const QIcon icon = action->icon();
             if(!icon.isNull()) {
+#ifndef QT_MAC_USE_COCOA
+                const short scale = GetMBarHeight();
+#else
                 const short scale = [[NSApp mainMenu] menuBarHeight];
+#endif
                 NSImage *nsimage = static_cast<NSImage *>(qt_mac_create_nsimage(icon.pixmap(QSize(scale, scale))));
                 [item setImage: nsimage];
                 [nsimage release];