diff options
-rw-r--r-- | src/gui/kernel/qwindow.cpp | 2 | ||||
-rw-r--r-- | src/platformsupport/inputcontext/qplatforminputcontextfactory_qpa.cpp | 14 |
2 files changed, 7 insertions, 9 deletions
diff --git a/src/gui/kernel/qwindow.cpp b/src/gui/kernel/qwindow.cpp index 6183b3f6ac..d43b37d080 100644 --- a/src/gui/kernel/qwindow.cpp +++ b/src/gui/kernel/qwindow.cpp @@ -59,7 +59,7 @@ #include <QtCore/QDebug> #include <QStyleHints> -#include <QPlatformCursor> +#include <qpa/qplatformcursor.h> QT_BEGIN_NAMESPACE diff --git a/src/platformsupport/inputcontext/qplatforminputcontextfactory_qpa.cpp b/src/platformsupport/inputcontext/qplatforminputcontextfactory_qpa.cpp index 6d909426a8..3e261ae765 100644 --- a/src/platformsupport/inputcontext/qplatforminputcontextfactory_qpa.cpp +++ b/src/platformsupport/inputcontext/qplatforminputcontextfactory_qpa.cpp @@ -58,24 +58,22 @@ Q_GLOBAL_STATIC_WITH_ARGS(QFactoryLoader, loader, QStringList QPlatformInputContextFactory::keys() { #if !defined(QT_NO_LIBRARY) && !defined(QT_NO_SETTINGS) - QStringList list = loader()->keys(); + return loader()->keyMap().values(); #else - QStringList list; + return QStringList(); #endif - return list; } QPlatformInputContext *QPlatformInputContextFactory::create(const QString& key) { - QPlatformInputContext *ret = 0; QStringList paramList = key.split(QLatin1Char(':')); - QString platform = paramList.takeFirst().toLower(); + const QString platform = paramList.takeFirst().toLower(); #if !defined(QT_NO_LIBRARY) && !defined(QT_NO_SETTINGS) - if (QPlatformInputContextFactoryInterface *factory = qobject_cast<QPlatformInputContextFactoryInterface*>(loader()->instance(platform))) - ret = factory->create(platform, paramList); + if (QPlatformInputContext *ret = qLoadPlugin1<QPlatformInputContext, QPlatformInputContextFactoryInterface>(loader(), platform, paramList)) + return ret; #endif - return ret; + return 0; } QPlatformInputContext *QPlatformInputContextFactory::create() |