Utils: Replace FilePath::rootPath() by some isRootPath()

Keeps more context to make it host-independent later.

Change-Id: I0f8ad3e8794daa6324662847203200ae378d34b4
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
hjk
2022-09-16 11:14:59 +02:00
parent eda8a4244f
commit 06334e1816
4 changed files with 12 additions and 13 deletions

View File

@@ -167,9 +167,10 @@ FilePath FilePath::currentWorkingPath()
return FilePath::fromString(QDir::currentPath());
}
FilePath FilePath::rootPath()
bool FilePath::isRootPath() const
{
return FilePath::fromString(QDir::rootPath());
// FIXME: Make host-independent
return operator==(FilePath::fromString(QDir::rootPath()));
}
QString FilePath::encodedHost() const