aboutsummaryrefslogtreecommitdiffstats
path: root/src/imports/folderlistmodel/fileinfothread.cpp
diff options
context:
space:
mode:
authorGatis Paeglis <gatis.paeglis@digia.com>2014-08-12 14:46:05 +0200
committerGatis Paeglis <gatis.paeglis@digia.com>2014-08-22 23:00:37 +0200
commit253e9257e1f586d1c1dfa585aa6f862d310cdec3 (patch)
tree4425049801c343aac4c39ee127104611b1484366 /src/imports/folderlistmodel/fileinfothread.cpp
parent3cc2b8d7d94361ef786304024fd2ddca4103f94b (diff)
Introspect qrc files in FolderListModel.
And don't use "file watchers" for resource file paths, otherwise it generates the following warning: QInotifyFileSystemWatcherEngine::addPaths: inotify_add_watch failed: No such file or directory Change-Id: I6b75c9195fb2b2ba7b3e0bb7d146fc5cd343927e Task-number: QTBUG-40307 Reviewed-by: Shawn Rutledge <shawn.rutledge@digia.com>
Diffstat (limited to 'src/imports/folderlistmodel/fileinfothread.cpp')
-rw-r--r--src/imports/folderlistmodel/fileinfothread.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/imports/folderlistmodel/fileinfothread.cpp b/src/imports/folderlistmodel/fileinfothread.cpp
index f7587c25f5..2d53b211ad 100644
--- a/src/imports/folderlistmodel/fileinfothread.cpp
+++ b/src/imports/folderlistmodel/fileinfothread.cpp
@@ -92,7 +92,8 @@ void FileInfoThread::removePath(const QString &path)
{
QMutexLocker locker(&mutex);
#ifndef QT_NO_FILESYSTEMWATCHER
- watcher->removePath(path);
+ if (!path.startsWith(QLatin1Char(':')))
+ watcher->removePath(path);
#endif
currentPath.clear();
}
@@ -103,7 +104,8 @@ void FileInfoThread::setPath(const QString &path)
QMutexLocker locker(&mutex);
#ifndef QT_NO_FILESYSTEMWATCHER
- watcher->addPath(path);
+ if (!path.startsWith(QLatin1Char(':')))
+ watcher->addPath(path);
#endif
currentPath = path;
needUpdate = true;