summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qplatformintegration.cpp
diff options
context:
space:
mode:
authorFrederik Gladhorn <frederik.gladhorn@digia.com>2013-10-04 00:42:24 +0200
committerFrederik Gladhorn <frederik.gladhorn@digia.com>2013-10-04 00:44:18 +0200
commitd8fc0da235b2bd566b2b6f1e21218afdf2f34eb3 (patch)
treec0ca819521ed6901a83ab476fa822a886691d806 /src/gui/kernel/qplatformintegration.cpp
parent3649a6e61d823289d18be19387d7e3923dd90bd0 (diff)
parentcdf0c5905b3477c6cd01c519f883b7bb55447120 (diff)
Merge remote-tracking branch 'origin/stable' into dev
Conflicts: src/plugins/platforms/minimal/qminimalintegration.cpp src/plugins/platforms/offscreen/qoffscreenintegration.cpp Change-Id: Ica85deeab5c5038ac004718e25194b1157343480
Diffstat (limited to 'src/gui/kernel/qplatformintegration.cpp')
-rw-r--r--src/gui/kernel/qplatformintegration.cpp22
1 files changed, 14 insertions, 8 deletions
diff --git a/src/gui/kernel/qplatformintegration.cpp b/src/gui/kernel/qplatformintegration.cpp
index dc775bcb61..3f93856349 100644
--- a/src/gui/kernel/qplatformintegration.cpp
+++ b/src/gui/kernel/qplatformintegration.cpp
@@ -231,17 +231,23 @@ QPlatformServices *QPlatformIntegration::services() const
are never repositioned by the window manager. The default implementation returns true.
*/
-
/*!
- \fn QAbstractEventDispatcher *QPlatformIntegration::guiThreadEventDispatcher() const = 0
+ \fn QAbstractEventDispatcher *QPlatformIntegration::createEventDispatcher() const = 0
+
+ Factory function for the GUI event dispatcher. The platform plugin should create
+ and return a QAbstractEventDispatcher subclass when this function is called.
+
+ If the platform plugin for some reason creates the event dispatcher outside of
+ this function (for example in the constructor), it needs to handle the case
+ where this function is never called, ensuring that the event dispatcher is
+ still deleted at some point (typically in the destructor).
+
+ Note that the platform plugin should never explicitly set the event dispatcher
+ itself, using QCoreApplication::setEventDispatcher(), but let QCoreApplication
+ decide when and which event dispatcher to create.
- Accessor function for the event dispatcher. The platform plugin should create
- an instance of the QAbstractEventDispatcher in its constructor and set it
- on the application using QGuiApplicationPrivate::instance()->setEventDispatcher().
- The event dispatcher is owned by QGuiApplication, the accessor should return
- a flat pointer.
- \sa QGuiApplicationPrivate
+ \since 5.2
*/
bool QPlatformIntegration::hasCapability(Capability cap) const