diff options
author | Tobias Hunger <tobias.hunger@qt.io> | 2017-05-03 14:17:18 +0200 |
---|---|---|
committer | Marco Benelli <marco.benelli@qt.io> | 2017-05-03 12:28:04 +0000 |
commit | b84aa8e837ea9146fd1882eeef43a68fb12620cf (patch) | |
tree | 321300986c04bc594ca1e3f7ca35405dcb1777f7 | |
parent | ccdf3354253b7d13cf2ae4b403eb51e46b4e9d77 (diff) | |
download | qt-creator-b84aa8e837ea9146fd1882eeef43a68fb12620cf.tar.gz |
ResourceNode: Set proper fileType based on file name
Set the fileType of ResourceFiles based on their file name. This
makes sure that QML files will be treated as QML, which fixes e.g.
QTCREATORBUG-18032 (and probably other strange bugs).
Task-number: QTCREATORBUG-18032
Change-Id: I05b1048d998ea1bed196611d529771c582bce441
Reviewed-by: Marco Benelli <marco.benelli@qt.io>
-rw-r--r-- | src/plugins/resourceeditor/resourcenode.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/resourceeditor/resourcenode.cpp b/src/plugins/resourceeditor/resourcenode.cpp index ffe74eeb42..cdf418ec43 100644 --- a/src/plugins/resourceeditor/resourcenode.cpp +++ b/src/plugins/resourceeditor/resourcenode.cpp @@ -658,7 +658,7 @@ ResourceTopLevelNode *ResourceFolderNode::resourceNode() const } ResourceFileNode::ResourceFileNode(const FileName &filePath, const QString &qrcPath, const QString &displayName) - : FileNode(filePath, FileType::Unknown, false) + : FileNode(filePath, FileNode::fileTypeForFileName(filePath), false) , m_qrcPath(qrcPath) , m_displayName(displayName) { |