path: root/src/corelib/io/qfilesystementry.cpp
diff options
authorMaurice Kalinowski <>2013-11-01 16:16:15 +0100
committerThe Qt Project <>2013-11-05 08:17:35 +0100
commit2ff0746e97acf37600b104838c96468f00953737 (patch)
tree9355da6854ad90ab38133d4d2133a3b5184c35fc /src/corelib/io/qfilesystementry.cpp
parentaf0409d336e07c61734777117f79906e0e82cd95 (diff)
Refactor plugin loading for WinRT
Specify the root directory to be the package root. Only plugins inside the root can be opened (actually also only files). Furthermore current defaults to the package root now, which in most cases is identical to previous behavior. When attempting to load a plugin the path can either be specified in host format "C:/..." or as plugin absolute "/platforms/...". Check for both, with preference of latter case, like when qt.conf is used with / being used as plugin path. Change-Id: I7e3da293362488b62a3357c4882ebf5e048dcf95 Reviewed-by: Friedemann Kleint <> Reviewed-by: Andrew Knight <> Reviewed-by: Oliver Wolff <>
Diffstat (limited to 'src/corelib/io/qfilesystementry.cpp')
1 files changed, 6 insertions, 0 deletions
diff --git a/src/corelib/io/qfilesystementry.cpp b/src/corelib/io/qfilesystementry.cpp
index 3934c6a673..42a724670e 100644
--- a/src/corelib/io/qfilesystementry.cpp
+++ b/src/corelib/io/qfilesystementry.cpp
@@ -170,6 +170,12 @@ void QFileSystemEntry::resolveNativeFilePath() const
m_nativeFilePath = QFile::encodeName(QDir::toNativeSeparators(m_filePath));
+#ifdef Q_OS_WINRT
+ while (m_nativeFilePath.startsWith(QLatin1Char('\\')))
+ m_nativeFilePath.remove(0,1);
+ if (m_nativeFilePath.isEmpty())
+ m_nativeFilePath.append(QLatin1Char('.'));