summaryrefslogtreecommitdiff
path: root/src/webenginequick/ui_delegates_manager.cpp
diff options
context:
space:
mode:
authorBalazs Egedi <egedib@inf.u-szeged.hu>2021-06-16 14:55:18 +0200
committerMichal Klocek <michal.klocek@qt.io>2021-07-06 13:05:49 +0000
commita060012ecef7ecc60f5518b6718136b22a10dc6b (patch)
treef8caddb6190f3a4bea0b8e1e161b9e0708333181 /src/webenginequick/ui_delegates_manager.cpp
parentccb3fece7d9306bf2c02fcd80505d6a4c3822f35 (diff)
downloadqtwebengine-a060012ecef7ecc60f5518b6718136b22a10dc6b.tar.gz
Remove Quick Controls 1 UIDelegates and introduce UIDelegates test
- Renamed Controls2Delegates to ControlsDelegates - Removed option to use Quick Controls 1 delegates - Added test to check if controls are shown Task-number: QTBUG-93666 Change-Id: Iccca948615309285db7fc57d14fb1cdcdef28051 Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: Peter Varga <pvarga@inf.u-szeged.hu> (cherry picked from commit 4fe808a8c0ecd143199781e9644a46e4b1b90653) Reviewed-by: Allan Sandfeld Jensen <allan.jensen@qt.io>
Diffstat (limited to 'src/webenginequick/ui_delegates_manager.cpp')
-rw-r--r--src/webenginequick/ui_delegates_manager.cpp18
1 files changed, 6 insertions, 12 deletions
diff --git a/src/webenginequick/ui_delegates_manager.cpp b/src/webenginequick/ui_delegates_manager.cpp
index 756b3429e..02f0f124f 100644
--- a/src/webenginequick/ui_delegates_manager.cpp
+++ b/src/webenginequick/ui_delegates_manager.cpp
@@ -658,22 +658,16 @@ bool UI2DelegatesManager::initializeImportDirs(QStringList &dirs, QQmlEngine *en
{
const QStringList paths = engine->importPathList();
for (const QString &path : paths) {
- QString controls2ImportPath = path % QLatin1String("/QtWebEngine/Controls2Delegates/");
- QString controls1ImportPath = path % QLatin1String("/QtWebEngine/Controls1Delegates/");
+ QString controlsImportPath = path % QLatin1String("/QtWebEngine/ControlsDelegates/");
// resource paths have to be tested using the ":/" prefix
- if (controls2ImportPath.startsWith(QLatin1String("qrc:/"))) {
- controls2ImportPath.remove(0, 3);
- controls1ImportPath.remove(0, 3);
+ if (controlsImportPath.startsWith(QLatin1String("qrc:/"))) {
+ controlsImportPath.remove(0, 3);
}
- QFileInfo fi2(controls2ImportPath);
- if (fi2.exists())
- dirs << fi2.absolutePath();
-
- QFileInfo fi1(controls1ImportPath);
- if (fi1.exists())
- dirs << fi1.absolutePath();
+ QFileInfo fi(controlsImportPath);
+ if (fi.exists())
+ dirs << fi.absolutePath();
}
return !dirs.isEmpty();
}