diff options
author | hjk <hjk@qt.io> | 2019-05-28 13:49:26 +0200 |
---|---|---|
committer | hjk <hjk@qt.io> | 2019-05-28 12:23:26 +0000 |
commit | 473a741c9fcf09febba312464fab8385e2351181 (patch) | |
tree | 2d328a090993cb5c5fd34b43e9468bcbf7e4d4d0 /src/plugins/qmldesigner/components/integration | |
parent | 4704f49fbb1201ebf10ab9dbaed0275ff25faba8 (diff) |
Utils: Rename FileName to FilePath
More in line with QFileInfo terminonlogy which appears to be
best-of-breed within Qt.
Change-Id: I1d051ff1c8363ebd4ee56376451df45216c4c9ab
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
Diffstat (limited to 'src/plugins/qmldesigner/components/integration')
-rw-r--r-- | src/plugins/qmldesigner/components/integration/designdocument.cpp | 10 | ||||
-rw-r--r-- | src/plugins/qmldesigner/components/integration/designdocument.h | 4 |
2 files changed, 7 insertions, 7 deletions
diff --git a/src/plugins/qmldesigner/components/integration/designdocument.cpp b/src/plugins/qmldesigner/components/integration/designdocument.cpp index d1b8586b5ab..a10225cc069 100644 --- a/src/plugins/qmldesigner/components/integration/designdocument.cpp +++ b/src/plugins/qmldesigner/components/integration/designdocument.cpp @@ -196,7 +196,7 @@ QString DesignDocument::simplfiedDisplayName() const return rootModelNode().simplifiedTypeName(); } -void DesignDocument::updateFileName(const Utils::FileName & /*oldFileName*/, const Utils::FileName &newFileName) +void DesignDocument::updateFileName(const Utils::FilePath & /*oldFileName*/, const Utils::FilePath &newFileName) { if (m_documentModel) m_documentModel->setFileUrl(QUrl::fromLocalFile(newFileName.toString())); @@ -209,11 +209,11 @@ void DesignDocument::updateFileName(const Utils::FileName & /*oldFileName*/, con emit displayNameChanged(displayName()); } -Utils::FileName DesignDocument::fileName() const +Utils::FilePath DesignDocument::fileName() const { if (editor()) return editor()->document()->filePath(); - return Utils::FileName(); + return Utils::FilePath(); } Kit *DesignDocument::currentKit() const @@ -250,7 +250,7 @@ void DesignDocument::loadDocument(QPlainTextEdit *edit) m_inFileComponentTextModifier.reset(); - updateFileName(Utils::FileName(), fileName()); + updateFileName(Utils::FilePath(), fileName()); updateQrcFiles(); @@ -287,7 +287,7 @@ void DesignDocument::updateQrcFiles() ProjectExplorer::Project *currentProject = ProjectExplorer::SessionManager::projectForFile(fileName()); if (currentProject) { - for (const Utils::FileName &fileName : currentProject->files(ProjectExplorer::Project::SourceFiles)) { + for (const Utils::FilePath &fileName : currentProject->files(ProjectExplorer::Project::SourceFiles)) { if (fileName.endsWith(".qrc")) QmlJS::ModelManagerInterface::instance()->updateQrcFile(fileName.toString()); } diff --git a/src/plugins/qmldesigner/components/integration/designdocument.h b/src/plugins/qmldesigner/components/integration/designdocument.h index 0bb5377c6de..eba0cf40606 100644 --- a/src/plugins/qmldesigner/components/integration/designdocument.h +++ b/src/plugins/qmldesigner/components/integration/designdocument.h @@ -90,7 +90,7 @@ public: TextEditor::BaseTextEditor *textEditor() const; QPlainTextEdit *plainTextEdit() const; - Utils::FileName fileName() const; + Utils::FilePath fileName() const; ProjectExplorer::Kit *currentKit() const; bool isDocumentLoaded() const; @@ -121,7 +121,7 @@ public: void changeToMaster(); private: // functions - void updateFileName(const Utils::FileName &oldFileName, const Utils::FileName &newFileName); + void updateFileName(const Utils::FilePath &oldFileName, const Utils::FilePath &newFileName); void changeToInFileComponentModel(ComponentTextModifier *textModifer); |