summaryrefslogtreecommitdiffstats
path: root/src/corelib/kernel/qcoreapplication.cpp
diff options
context:
space:
mode:
authorDenis Dzyubenko <denis.dzyubenko@nokia.com>2010-04-21 12:56:40 (GMT)
committerDenis Dzyubenko <denis.dzyubenko@nokia.com>2010-05-03 15:31:27 (GMT)
commite4c60e6b8d111c6214d8ee47b8c2bb8b9f8fcfe2 (patch)
tree8966060ea690d99ff40eee700e2a5a7064c41984 /src/corelib/kernel/qcoreapplication.cpp
parent3d852917187e29892529ab51d24c1a1177068a88 (diff)
downloadQt-e4c60e6b8d111c6214d8ee47b8c2bb8b9f8fcfe2.zip
Qt-e4c60e6b8d111c6214d8ee47b8c2bb8b9f8fcfe2.tar.gz
Qt-e4c60e6b8d111c6214d8ee47b8c2bb8b9f8fcfe2.tar.bz2
Support updating system locale data on Symbian
Subscribing to the locale change notification to be able to update the system locale whenever the user changes the current system locale. Task-number: QTBUG-4870 Reviewed-by: Thomas Zander Reviewed-by: Jason Barron
Diffstat (limited to 'src/corelib/kernel/qcoreapplication.cpp')
-rw-r--r--src/corelib/kernel/qcoreapplication.cpp13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/corelib/kernel/qcoreapplication.cpp b/src/corelib/kernel/qcoreapplication.cpp
index bf2e2e4..f44fe99 100644
--- a/src/corelib/kernel/qcoreapplication.cpp
+++ b/src/corelib/kernel/qcoreapplication.cpp
@@ -63,6 +63,7 @@
#include <qvarlengtharray.h>
#include <private/qfactoryloader_p.h>
#include <private/qfunctions_p.h>
+#include <private/qlocale_p.h>
#ifdef Q_OS_SYMBIAN
# include <exception>
@@ -521,6 +522,9 @@ QCoreApplication::QCoreApplication(int &argc, char **argv)
QFactoryLoader::refreshAll();
#endif
+#if defined(Q_OS_SYMBIAN) && !defined(QT_NO_SYSTEMLOCALE)
+ d_func()->symbianInit();
+#endif
}
// ### move to QCoreApplicationPrivate constructor?
@@ -597,6 +601,15 @@ void QCoreApplication::init()
qt_startup_hook();
}
+#if defined(Q_OS_SYMBIAN) && !defined(QT_NO_SYSTEMLOCALE)
+void QCoreApplicationPrivate::symbianInit()
+{
+ if (!environmentChangeNotifier)
+ environmentChangeNotifier.reset(new QEnvironmentChangeNotifier);
+}
+#endif
+
+
/*!
Destroys the QCoreApplication object.
*/