Commit 384641d7 authored by Orgad Shaneh's avatar Orgad Shaneh Committed by Orgad Shaneh
Browse files

Suppress "file outside the project" warning when there is no project



Change-Id: I46f6e38ba167a85b17ae9f7ac89d5fbbc75abfcd
Reviewed-by: default avatarDaniel Teske <daniel.teske@theqtcompany.com>
parent 9007d2cb
......@@ -334,7 +334,10 @@ void ProjectTree::updateExternalFileWarning()
if (!infoBar->canInfoBeAdded(externalFileId))
return;
Utils::FileName fileName = Utils::FileName::fromString(document->filePath());
foreach (Project *project, SessionManager::projects()) {
const QList<Project *> projects = SessionManager::projects();
if (projects.isEmpty())
return;
foreach (Project *project, projects) {
Utils::FileName projectDir = project->projectDirectory();
if (projectDir.isEmpty())
continue;
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment