summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qevent.cpp
diff options
context:
space:
mode:
authorSamuel Gaist <samuel.gaist@edeltech.ch>2015-11-23 15:10:46 +0100
committerSamuel Gaist <samuel.gaist@edeltech.ch>2015-11-24 23:46:12 +0000
commit68d100692b7175f62bdf1c9e5b899cec14d7e259 (patch)
tree74f37f4532d1d470242d10338c1d58aefcbccd61 /src/gui/kernel/qevent.cpp
parent5c7f000cd4c9e3769e8cd4085cf0beee104f9886 (diff)
Doc: added sample to QFileOpenEvent class details
This sample will help user needing to react on QFileOpenEvent get started faster. Change-Id: I7def292894fc39d803f70cbf0453f6791b7aea15 Reviewed-by: Topi Reiniƶ <topi.reinio@theqtcompany.com>
Diffstat (limited to 'src/gui/kernel/qevent.cpp')
-rw-r--r--src/gui/kernel/qevent.cpp15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/gui/kernel/qevent.cpp b/src/gui/kernel/qevent.cpp
index 0bb21752bc..2ca17692db 100644
--- a/src/gui/kernel/qevent.cpp
+++ b/src/gui/kernel/qevent.cpp
@@ -3417,6 +3417,21 @@ QShowEvent::~QShowEvent()
It may be safely ignored.
\note This class is currently supported for OS X only.
+
+ \section1 OS X Example
+
+ In order to trigger the event on OS X, the application must be configured
+ to let the OS know what kind of file(s) it should react on.
+
+ For example, the following \c Info.plist file declares that the application
+ can act as a viewer for files with a PNG extension:
+
+ \snippet qfileopenevent/Info.plist Custom Info.plist
+
+ The following implementation of a QApplication subclass prints the path to
+ the file that was, for example, dropped on the Dock icon of the application.
+
+ \snippet qfileopenevent/main.cpp QApplication subclass
*/
/*!