qt5base-lts/tests/manual/dialogs
Shawn Rutledge b5eb850e0d OSX: add several menuitem roles to support menu shortcuts in dialogs
Now menu items and key shortcuts for Cut, Copy, Paste and Select All
work in the standard ways in dialogs such as the file dialog, provided
that the corresponding QActions have been created and added to the menu.
This depends on new roles to identify each menu item which is so
broadly applicable that it should work even when a native widget has
focus; but the role will be auto-detected, just as we were already
doing for application menu items such as Quit, About and Preferences.
When the QFileDialog is opened, it will call
redirectKnownMenuItemsToFirstResponder() which will make only those
"special" menu items have the standard actions and nil targets.  When
the dialog is dismissed, those NSMenuItems must be reverted by calling
resetKnownMenuItemsToQt(), because to invoke a QAction, the NSMenuItem's
action should be itemFired and the target should be the
QCocoaMenuDelegate.

Task-number: QTBUG-17291
Change-Id: I501375ca6fa13fac75d4b4fdcede993ec2329cc7
Reviewed-by: Morten Johan Sørvig <morten.sorvig@digia.com>
2014-04-07 08:30:24 +02:00
..
colordialogpanel.cpp Update manualtests license to say "part of test suite". 2013-05-26 20:54:51 +02:00
colordialogpanel.h Manual test: fix compilation with namespaced Qt 2013-06-14 11:26:21 +02:00
dialogs.pro QPrintDialog - Convert manual test to .ui file 2014-03-25 00:00:23 +01:00
filedialogpanel.cpp Add QFileDialog::ShowDirsOnly to manual dialog test. 2013-12-10 15:14:22 +01:00
filedialogpanel.h Add QFileDialog::ShowDirsOnly to manual dialog test. 2013-12-10 15:14:22 +01:00
fontdialogpanel.cpp Fix compilation of the manual dialogs test with Qt 4. 2013-11-01 16:37:36 +01:00
fontdialogpanel.h Manual test: fix compilation with namespaced Qt 2013-06-14 11:26:21 +02:00
main.cpp OSX: add several menuitem roles to support menu shortcuts in dialogs 2014-04-07 08:30:24 +02:00
messageboxpanel.cpp Fix compilation of the manual dialogs test with Qt 4. 2013-11-01 16:37:36 +01:00
messageboxpanel.h QMessageBox - make it possible to have a checkbox on the dialog 2013-09-20 22:02:00 +02:00
printdialogpanel.cpp QPrintDialog - Add Direct print to manual test 2014-04-05 21:48:03 +02:00
printdialogpanel.h QPrintDialog - Add Direct print to manual test 2014-04-05 21:48:03 +02:00
printdialogpanel.ui QPrintDialog - Add Direct print to manual test 2014-04-05 21:48:03 +02:00
utils.cpp QPrintDialog - Convert manual test to .ui file 2014-03-25 00:00:23 +01:00
utils.h QPrintDialog - Convert manual test to .ui file 2014-03-25 00:00:23 +01:00
wizardpanel.cpp Update manualtests license to say "part of test suite". 2013-05-26 20:54:51 +02:00
wizardpanel.h Manual test: fix compilation with namespaced Qt 2013-06-14 11:26:21 +02:00