diff options
author | Miguel Costa <miguel.costa@qt.io> | 2020-12-15 12:18:21 +0100 |
---|---|---|
committer | Miguel Costa <miguel.costa@qt.io> | 2020-12-17 13:20:47 +0000 |
commit | 7fdf9e7cf0f4a8098a8159269e2f864a45331733 (patch) | |
tree | 627e21e1d0bd024b5c8c2d6589dbd871cd645856 | |
parent | cb9ec156845a9efc163a9c67d7a54c8ca790e805 (diff) |
Fix QML debug not working without a QRC file
Fixed a bug where QML debugging would only work if a QRC was present in
the project being debugged.
Task-number: QTVSADDINBUG-755
Change-Id: Ie69c1f98abd4becec5030d0e5bd71bb57d268276
Reviewed-by: Joerg Bornemann <joerg.bornemann@qt.io>
-rw-r--r-- | src/qtvstools/QML/Debugging/QmlFileSystem.cs | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/src/qtvstools/QML/Debugging/QmlFileSystem.cs b/src/qtvstools/QML/Debugging/QmlFileSystem.cs index 9c627b8c..fe794ad2 100644 --- a/src/qtvstools/QML/Debugging/QmlFileSystem.cs +++ b/src/qtvstools/QML/Debugging/QmlFileSystem.cs @@ -191,10 +191,14 @@ namespace QtVsTools.Qml.Debug } QmlFile file; - if (!files.TryGetValue(fullPath, out file)) - return default(QmlFile); + if (files.TryGetValue(fullPath, out file)) + return file; - return file; + return new QmlFile + { + FilePath = fullPath, + QrcPath = new Uri(fullPath).ToString().ToLower() + }; } public QmlFile this[string path] |