Clang: Rename isProjectPartValid to isProjectPartLoaded

Change-Id: Ib20700ebb7142cfa9e75edff3b21410fd3bdab05
Reviewed-by: Marco Bubke <marco.bubke@theqtcompany.com>
This commit is contained in:
Nikolai Kosjar
2015-09-24 14:25:53 +02:00
parent 143983a857
commit c45f08cdae
3 changed files with 4 additions and 4 deletions

View File

@@ -227,7 +227,7 @@ ClangEditorDocumentProcessor *ClangEditorDocumentProcessor::get(const QString &f
static bool isProjectPartLoadedOrIsFallback(CppTools::ProjectPart::Ptr projectPart)
{
return projectPart
&& (projectPart->id().isEmpty() || ClangCodeModel::Utils::isProjectPartValid(projectPart));
&& (projectPart->id().isEmpty() || ClangCodeModel::Utils::isProjectPartLoaded(projectPart));
}
void ClangEditorDocumentProcessor::updateProjectPartAndTranslationUnitForEditor()

View File

@@ -273,7 +273,7 @@ ProjectPart::Ptr projectPartForFileBasedOnProcessor(const QString &filePath)
return ProjectPart::Ptr();
}
bool isProjectPartValid(const ProjectPart::Ptr projectPart)
bool isProjectPartLoaded(const ProjectPart::Ptr projectPart)
{
if (projectPart)
return CppModelManager::instance()->projectPartForId(projectPart->id());
@@ -284,7 +284,7 @@ QString projectPartIdForFile(const QString &filePath)
{
const ProjectPart::Ptr projectPart = projectPartForFile(filePath);
if (isProjectPartValid(projectPart))
if (isProjectPartLoaded(projectPart))
return projectPart->id(); // OK, Project Part is still loaded
return QString();
}

View File

@@ -55,7 +55,7 @@ QStringList createPCHInclusionOptions(const QString &pchFile);
CppTools::ProjectPart::Ptr projectPartForFile(const QString &filePath);
CppTools::ProjectPart::Ptr projectPartForFileBasedOnProcessor(const QString &filePath);
bool isProjectPartValid(const CppTools::ProjectPart::Ptr projectPart);
bool isProjectPartLoaded(const CppTools::ProjectPart::Ptr projectPart);
QString projectPartIdForFile(const QString &filePath);
} // namespace Utils