aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFriedemann Kleint <Friedemann.Kleint@theqtcompany.com>2016-02-26 09:34:41 +0100
committerFriedemann Kleint <Friedemann.Kleint@theqtcompany.com>2016-02-29 09:13:36 +0000
commit79f6da1b90c2a1a0a39084b7ab79f1dedc5caa25 (patch)
tree9f782e680b768368ef2ce4668428ea5944c788b5
parent492df3d63ccb21374c7eddd9666e74a378a06904 (diff)
Use new template function qLoadPlugin().
Fix deprecation warning: gamepadbackendfactory.cpp: In static member function ‘static QGamepadBackend* QGamepadBackendFactory::create(const QString&, const QStringList&, const QString&)’: qgamepadbackendfactory.cpp:80:115: warning: ‘PluginInterface* qLoadPlugin1(const QFactoryLoader*, const QString&, Arg&&) [with PluginInterface = QGamepadBackend; FactoryInterface = QGamepadBackendPlugin; Arg = const QStringList&]’ is deprecated (declared at qtbase/include/QtCore/5.7.0/QtCore/private/../../../../../src/corelib/plugin/qfactoryloader_p.h:172) [-Wdeprecated-declarations] if (QGamepadBackend *ret = qLoadPlugin1<QGamepadBackend, QGamepadBackendPlugin>(directLoader(), name, args)) ^ qgamepadbackendfactory.cpp:83:105: warning: ‘PluginInterface* qLoadPlugin1(const QFactoryLoader*, const QString&, Arg&&) [with PluginInterface = QGamepadBackend; FactoryInterface = QGamepadBackendPlugin; Arg = const QStringList&]’ is deprecated (declared at qtbase/include/QtCore/5.7.0/QtCore/private/../../../../../src/corelib/plugin/qfactoryloader_p.h:172) [-Wdeprecated-declarations] if (QGamepadBackend *ret = qLoadPlugin1<QGamepadBackend, QGamepadBackendPlugin>(loader(), name, args)) ^ Change-Id: I6b2ade29200ae8f47470bfa26b594ee1ab69823d Reviewed-by: Frederik Gladhorn <frederik.gladhorn@theqtcompany.com> Reviewed-by: Andy Nichols <andy.nichols@theqtcompany.com>
-rw-r--r--src/gamepad/qgamepadbackendfactory.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/gamepad/qgamepadbackendfactory.cpp b/src/gamepad/qgamepadbackendfactory.cpp
index 0434e4b..25a1064 100644
--- a/src/gamepad/qgamepadbackendfactory.cpp
+++ b/src/gamepad/qgamepadbackendfactory.cpp
@@ -77,10 +77,10 @@ QGamepadBackend *QGamepadBackendFactory::create(const QString &name, const QStri
#ifndef QT_NO_LIBRARY
if (!pluginPath.isEmpty()) {
QCoreApplication::addLibraryPath(pluginPath);
- if (QGamepadBackend *ret = qLoadPlugin1<QGamepadBackend, QGamepadBackendPlugin>(directLoader(), name, args))
+ if (QGamepadBackend *ret = qLoadPlugin<QGamepadBackend, QGamepadBackendPlugin>(directLoader(), name, args))
return ret;
}
- if (QGamepadBackend *ret = qLoadPlugin1<QGamepadBackend, QGamepadBackendPlugin>(loader(), name, args))
+ if (QGamepadBackend *ret = qLoadPlugin<QGamepadBackend, QGamepadBackendPlugin>(loader(), name, args))
return ret;
#endif
return 0;