diff options
| author | Dominik Holland <dominik.holland@qt.io> | 2022-12-06 09:38:14 +0100 |
|---|---|---|
| committer | Dominik Holland <dominik.holland@qt.io> | 2022-12-07 11:29:41 +0100 |
| commit | 948a66e9ef46331ef6b20ca52f0db8abefda1634 (patch) | |
| tree | df2b667ba7d009470934e02114f3d0685af775fd /src/interfaceframework/qifsimulationengine.cpp | |
| parent | c4e74d12c247ad090abbe9f4603bb5a9d28eddb5 (diff) | |
QIfSimulationEngine: Also accept local file paths instead of urls
Change-Id: Icc0159665e03497b970ac8177eebb765ac659e2a
Reviewed-by: Robert Griebl <robert.griebl@qt.io>
Diffstat (limited to 'src/interfaceframework/qifsimulationengine.cpp')
| -rw-r--r-- | src/interfaceframework/qifsimulationengine.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/interfaceframework/qifsimulationengine.cpp b/src/interfaceframework/qifsimulationengine.cpp index fe556ae4..e4c89d5f 100644 --- a/src/interfaceframework/qifsimulationengine.cpp +++ b/src/interfaceframework/qifsimulationengine.cpp @@ -27,6 +27,8 @@ namespace qtif_helper { return path; else if (path.startsWith(resourceLiteral)) return QString(path).prepend(qrcLiteral); + else if (QFile::exists(path)) // If the file exists a normal path was passed (instead of a url) + return QUrl::fromLocalFile(path); return path; } } |
