summaryrefslogtreecommitdiffstats
path: root/src/plugins/platforms/cocoa/qcocoaapplicationdelegate.h
Commit message (Collapse)AuthorAgeFilesLines
* Cocoa: re-enable getUrl: and appleEventQuit: AppleEvent handlersBradley T. Hughes2012-06-121-0/+1
| | | | | | | | | | | | | | | | | | | The getUrl: and appleEventQuit: handlers are only called if we register them with the NSAppleEventManager. The Cocoa documentation says the best place to do this is in the applicationWillFinishLaunching: delegate method, so add this method and move the code from qcocoaeventdispatcher.mm to there. Since QCocoaApplicationDelegate is only used when AA_MacPluginApplication is not set, we do not need to check again in the delegate code. Be sure to remove these event handlers when shutting down the application. For the getUrl: handler, send file open events when receiving this event. This restores Qt 4 behavior. Remove the qDebug() from the appleEventQuit: handler. Change-Id: Ibcbdd541695176e3d236366d4d541e4811882d6c Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Cocoa: Remove unused QApplicationPrivate from QCocoaApplicationDelegateBradley T. Hughes2012-06-121-5/+0
| | | | | | | | | | To avoid a QtWidget dependency, we should use QGuiApplicationPrivate isntead, but instead of storing, we can use QGuiAppliationPrivate::instance() instead. Change-Id: If3f63fee804b7ad32fe8d612bf70c051b70f54c8 Reviewed-by: James Turner <james.turner@kdab.com> Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>
* Remove "All rights reserved" line from license headers.Jason McDonald2012-01-301-1/+1
| | | | | | | | | | As in the past, to avoid rewriting various autotests that contain line-number information, an extra blank line has been inserted at the end of the license text to ensure that this commit does not change the total number of lines in the license header. Change-Id: I311e001373776812699d6efc045b5f742890c689 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update contact information in license headers.Jason McDonald2012-01-231-1/+1
| | | | | | | Replace Nokia contact email address with Qt Project website. Change-Id: I431bbbf76d7c27d8b502f87947675c116994c415 Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Update copyright year in license headers.Jason McDonald2012-01-051-1/+1
| | | | | Change-Id: I02f2c620296fcd91d4967d58767ea33fc4e1e7dc Reviewed-by: Rohan McGovern <rohan.mcgovern@nokia.com>
* Cocoa: QMenu refactor.Morten Sorvig2011-09-071-0/+127
This change prepares for enabling native menus on OS X. Move code from src/widgets to cocoa: - qcocoaapplicaiton - qcocoaapplicaitondelegate - qcocoamenuloader - qcocoamenu - qmenu_mac - misc helpers to qcocoahelpers Create a QNSApplication and QCocoaApplicationDelegate at application startup. New Lighthouse API: - class QPlatformMenu - class QPlatformMenuBar - QPlatformIntegration::createPlatformMenu() - QPlatformIntegration::createPlatformMenuBar() Platforms that wants a native menu integration subclasses QPlatformMenu[|Bar] and implements the create function. The default implementation returns 0, which causes QMenu to use the standard Qt menus. This API is based on the current native menu abstraction that Mac, Wince and S60 uses in Qt 4. The main difference is that the platform classes are proper standalone classes and not #ifdeffed into QMenuPrivate. Change-Id: I3da41f80b0ae903a476937908b1f9b88014b7954 Reviewed-on: http://codereview.qt.nokia.com/4068 Reviewed-by: Morten Johan Sørvig <morten.sorvig@nokia.com>