Details
-
Bug
-
Resolution: Fixed
-
P2: Important
-
Qt Creator 6.0.2
-
a235aa29a1 (qt-creator/qt-creator/8.0) a235aa29a1 (qt-creator/qt-creator/master) a235aa29a1 (qt-creator/tqtc-qt-creator/8.0) 129448d61d (qt-creator/qt-creator/9.0) 129448d61d (qt-creator/qt-creator/qds/dev) 129448d61d (qt-creator/qt-creator/master)
Description
If QML modules are made through qt_add_qml_module, qml files there are copied to build directory as they should be. However, because import path points to build directory, Qt Creator opens qml files from that build directory instead of from source directory.
To reproduce:
- build attached project
- Tools -> QML/JS -> Reset code model
- open main.qml
- ctrl+click Broken component there
this opens the file from build directory.
This is a big problem as it can lead to lost code as the file is overridden by the build process so all changes user might do would disappear.
While this is probably pretty hard to fix, maybe a simple fix would be to make Qt Creator display a banner saying that the file is generated or just that it exists in the build directory. Or maybe even doesn't allow editing it (read-only) by default.
Attachments
Issue Links
- depends on
-
QTCREATORBUG-28008 Add a way to link a generated qmldir file back to the source folder
- Reported
- split to
-
QTCREATORBUG-28008 Add a way to link a generated qmldir file back to the source folder
- Reported
- mentioned in
-
Page Loading...
For Gerrit Dashboard: QTCREATORBUG-27173 | ||||||
---|---|---|---|---|---|---|
# | Subject | Branch | Project | Status | CR | V |
410048,3 | QmlJSEditor: Show warning if opened QML/JS file is not in any project | master | qt-creator/qt-creator | Status: ABANDONED | +1 | 0 |
410314,4 | Warn when editing generated files | master | qt-creator/qt-creator | Status: MERGED | +2 | 0 |
411243,3 | qmljs: avoid linking to files in the build directory | 7.0 | qt-creator/qt-creator | Status: ABANDONED | 0 | 0 |
417020,4 | qmljs: avoid linking to files in the build directory | 8.0 | qt-creator/qt-creator | Status: MERGED | +2 | 0 |
440008,22 | QmlJS: Fix Follow under cursor | 9.0 | qt-creator/qt-creator | Status: MERGED | +2 | 0 |