summaryrefslogtreecommitdiffstats
path: root/src/gui/kernel/qapplication_s60.cpp
diff options
context:
space:
mode:
authorLaszlo Agocs <laszlo.p.agocs@nokia.com>2011-04-14 07:13:42 (GMT)
committerLaszlo Agocs <laszlo.p.agocs@nokia.com>2011-04-14 07:13:42 (GMT)
commita5898f33f215ff2ac333be61306a47ca162b2104 (patch)
tree6d0e60b465378e0bf61d990e621c406f7408888e /src/gui/kernel/qapplication_s60.cpp
parentd176e39de8fcde92a92866e7b0db5904c90a1e82 (diff)
downloadQt-a5898f33f215ff2ac333be61306a47ca162b2104.zip
Qt-a5898f33f215ff2ac333be61306a47ca162b2104.tar.gz
Qt-a5898f33f215ff2ac333be61306a47ca162b2104.tar.bz2
Trigger fullscreen transition effects properly on app exit.
Avkon calls BeginFullScreen() and EndFullScreen() to trigger the fullscreen system transition effects for application exit, however the calls are made too late for Qt apps because the widgets are already destroyed. Instead, the effects are triggered explicitly from Qt, before closing the widgets, or from aboutToQuit, whichever comes first. Task-number: QT-4718 Reviewed-by: Jani Hautakangas
Diffstat (limited to 'src/gui/kernel/qapplication_s60.cpp')
-rw-r--r--src/gui/kernel/qapplication_s60.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/src/gui/kernel/qapplication_s60.cpp b/src/gui/kernel/qapplication_s60.cpp
index 6e70fc2..6620efd 100644
--- a/src/gui/kernel/qapplication_s60.cpp
+++ b/src/gui/kernel/qapplication_s60.cpp
@@ -1828,9 +1828,7 @@ void qt_init(QApplicationPrivate * /* priv */, int)
systemFont.setFamily(systemFont.defaultFamily());
QApplicationPrivate::setSystemFont(systemFont);
-#ifdef Q_SYMBIAN_TRANSITION_EFFECTS
QObject::connect(qApp, SIGNAL(aboutToQuit()), qApp, SLOT(_q_aboutToQuit()));
-#endif
#ifdef Q_SYMBIAN_SEMITRANSPARENT_BG_SURFACE
QApplicationPrivate::instance()->useTranslucentEGLSurfaces = true;
@@ -1921,6 +1919,9 @@ void qt_cleanup()
S60->setButtonGroupContainer(0);
#endif
+ // Call EndFullScreen() to prevent confusing the system effect state machine.
+ qt_endFullScreenEffect();
+
if (S60->qtOwnsS60Environment) {
// Restore the S60 framework trap handler. See qt_init().
User::SetTrapHandler(S60->s60InstalledTrapHandler);
@@ -2659,6 +2660,8 @@ void QApplication::restoreOverrideCursor()
void QApplicationPrivate::_q_aboutToQuit()
{
+ qt_beginFullScreenEffect();
+
#ifdef Q_SYMBIAN_TRANSITION_EFFECTS
// Send the shutdown tfx command
S60->wsSession().SendEffectCommand(ETfxCmdAppShutDown);