summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qsessionmanager.cpp
diff options
context:
space:
mode:
authorOswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>2016-03-07 16:53:34 +0100
committerOswald Buddenhagen <oswald.buddenhagen@theqtcompany.com>2016-03-07 17:08:56 +0100
commitf93032848e6b090b671d0035557a32bed65d2b4e (patch)
tree8cb6a0705c19d3cc6002f70ed5dddd0dd7adcab9 /src/gui/kernel/qsessionmanager.cpp
parentbcd88d8e9984bff664740aae3cff708a069dbbdd (diff)
parentd0cdc7ad1e2728caf363abf328b2ad81f2ed5a5b (diff)
Merge remote-tracking branch 'origin/5.6.0' into 5.7v5.7.0-alpha1
Diffstat (limited to 'src/gui/kernel/qsessionmanager.cpp')
-rw-r--r--src/gui/kernel/qsessionmanager.cpp19
1 files changed, 9 insertions, 10 deletions
diff --git a/src/gui/kernel/qsessionmanager.cpp b/src/gui/kernel/qsessionmanager.cpp
index f7414868d9..493a321c74 100644
--- a/src/gui/kernel/qsessionmanager.cpp
+++ b/src/gui/kernel/qsessionmanager.cpp
@@ -70,22 +70,21 @@ QT_BEGIN_NAMESPACE
settings.
QSessionManager provides an interface between the application and the
- session manager so that the program can work well with the session manager.
- In Qt, session management requests for action are handled by the two
- signals QGuiApplication::commitDataRequest() and
- QGuiApplication::saveStateRequest(). Both provide a reference to a session
- manager object as argument, to allow the application to communicate with
- the session manager. The session manager can only be accessed through these
- functions.
+ platform's session manager. In Qt, session management requests for action
+ are handled by the two signals QGuiApplication::commitDataRequest() and
+ QGuiApplication::saveStateRequest(). Both provide a reference to a
+ QSessionManager object as argument. The session manager can only be
+ accessed in slots invoked by these signals.
+
+ \warning If you use QSessionManager, you should disable fallback session
+ management: QGuiApplication::setFallbackSessionManagementEnabled().
No user interaction is possible \e unless the application gets explicit
permission from the session manager. You ask for permission by calling
allowsInteraction() or, if it is really urgent, allowsErrorInteraction().
Qt does not enforce this, but the session manager may.
- You can try to abort the shutdown process by calling cancel(). The default
- commitData() function does this if some top-level window rejected its
- closeEvent().
+ You can try to abort the shutdown process by calling cancel().
For sophisticated session managers provided on Unix/X11, QSessionManager
offers further possibilities to fine-tune an application's session