forked from qt-creator/qt-creator
BaseQtVersion: Use FilePath for demosPath()
Change-Id: I83bcbf64a37faf0f88c6b1f655ff3d5c5d7e623c Reviewed-by: hjk <hjk@qt.io>
This commit is contained in:
@@ -1257,9 +1257,9 @@ bool BaseQtVersion::hasDemos() const
|
||||
return d->m_hasDemos;
|
||||
}
|
||||
|
||||
QString BaseQtVersion::demosPath() const
|
||||
FilePath BaseQtVersion::demosPath() const
|
||||
{
|
||||
return QFileInfo(qmakeProperty("QT_INSTALL_DEMOS")).canonicalFilePath();
|
||||
return FilePath::fromString(QFileInfo(qmakeProperty("QT_INSTALL_DEMOS")).canonicalFilePath());
|
||||
}
|
||||
|
||||
QString BaseQtVersion::frameworkInstallPath() const
|
||||
@@ -1846,7 +1846,7 @@ bool BaseQtVersion::isSubProject(const FilePath &filePath) const
|
||||
if (!examples.isEmpty() && filePath.isChildOf(QDir(examples)))
|
||||
return true;
|
||||
|
||||
const QString &demos = demosPath();
|
||||
const QString demos = demosPath().toString();
|
||||
if (!demos.isEmpty() && filePath.isChildOf(QDir(demos)))
|
||||
return true;
|
||||
|
||||
|
@@ -147,10 +147,9 @@ public:
|
||||
|
||||
bool hasExamples() const;
|
||||
bool hasDocumentation() const;
|
||||
QString documentationPath() const;
|
||||
|
||||
bool hasDemos() const;
|
||||
QString demosPath() const;
|
||||
|
||||
QString documentationPath() const;
|
||||
|
||||
QString frameworkInstallPath() const;
|
||||
|
||||
@@ -203,6 +202,7 @@ public:
|
||||
virtual ProjectExplorer::Tasks validateKit(const ProjectExplorer::Kit *k);
|
||||
|
||||
Utils::FilePath headerPath() const;
|
||||
Utils::FilePath demosPath() const;
|
||||
Utils::FilePath docsPath() const;
|
||||
Utils::FilePath examplesPath() const;
|
||||
Utils::FilePath libraryPath() const;
|
||||
|
@@ -579,7 +579,7 @@ QStringList ExampleSetModel::exampleSources(QString *examplesInstallPath, QStrin
|
||||
if (version->uniqueId() == qtId) {
|
||||
manifestScanPath = version->documentationPath();
|
||||
examplesPath = version->examplesPath().toString();
|
||||
demosPath = version->demosPath();
|
||||
demosPath = version->demosPath().toString();
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user