summaryrefslogtreecommitdiffstats
path: root/src/corelib
diff options
context:
space:
mode:
authorSamuel Rødal <samuel.rodal@nokia.com>2010-09-07 09:49:34 (GMT)
committerSamuel Rødal <samuel.rodal@nokia.com>2010-09-10 10:44:56 (GMT)
commitb2ef75097e608afc717604884c4b6e4b22e78dee (patch)
tree40f9148eba79cfe7e82c9b771b465e953a3ea2ff /src/corelib
parent0d9c5bc460c66a96edc9416e5d7e5a56983562a4 (diff)
downloadQt-b2ef75097e608afc717604884c4b6e4b22e78dee.zip
Qt-b2ef75097e608afc717604884c4b6e4b22e78dee.tar.gz
Qt-b2ef75097e608afc717604884c4b6e4b22e78dee.tar.bz2
Use QFactoryLoader to ensure we get the correct graphics system plugin.
Also, this prevents hard-coding the path to the meego plugin.
Diffstat (limited to 'src/corelib')
-rw-r--r--src/corelib/plugin/qfactoryloader.cpp8
-rw-r--r--src/corelib/plugin/qfactoryloader_p.h4
2 files changed, 12 insertions, 0 deletions
diff --git a/src/corelib/plugin/qfactoryloader.cpp b/src/corelib/plugin/qfactoryloader.cpp
index 62d565a..a26dcd8 100644
--- a/src/corelib/plugin/qfactoryloader.cpp
+++ b/src/corelib/plugin/qfactoryloader.cpp
@@ -244,6 +244,14 @@ QObject *QFactoryLoader::instance(const QString &key) const
return 0;
}
+#ifdef Q_WS_X11
+QLibraryPrivate *QFactoryLoader::library(const QString &key) const
+{
+ Q_D(const QFactoryLoader);
+ return d->keyMap.value(d->cs ? key : key.toLower());
+}
+#endif
+
void QFactoryLoader::refreshAll()
{
QMutexLocker locker(qt_factoryloader_mutex());
diff --git a/src/corelib/plugin/qfactoryloader_p.h b/src/corelib/plugin/qfactoryloader_p.h
index 10e6e2a..068c6c7 100644
--- a/src/corelib/plugin/qfactoryloader_p.h
+++ b/src/corelib/plugin/qfactoryloader_p.h
@@ -77,6 +77,10 @@ public:
QStringList keys() const;
QObject *instance(const QString &key) const;
+#ifdef Q_WS_X11
+ QLibraryPrivate *library(const QString &key) const;
+#endif
+
void update();
static void refreshAll();