aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/projectexplorer/projecttree.h
diff options
context:
space:
mode:
authorDaniel Teske <daniel.teske@theqtcompany.com>2015-05-04 16:47:47 +0200
committerDaniel Teske <daniel.teske@theqtcompany.com>2015-05-06 11:58:10 +0000
commitd9425c5cc4fb5d7597ab92e661c1e724c5336dfa (patch)
treeb300f6bbbbf0a95949d9641671f95e979ce2eb06 /src/plugins/projectexplorer/projecttree.h
parent68a00c12a37f69441af73c7caba62499cf3acf1c (diff)
ProjectTree::currentProject: Introduce a fall back to startupProject
If no node is selected, e.g. no document is open, the ProjectTree currently claims that there is no current project. This adds a fallback to startup project in that case. This especially fixes the case where only one project is open and as such it is clear from context which project the user expects to be current. Revert a few places where I implemented this fallback manually. I do not like this. If multiple projects are open, this fallback can be surprising and not what the user wants. Everything works fine in the simple case with one project open but breaks with multiple projects open, this actively hides bugs. Change-Id: I6259834ca2220dd83bdffb16c3a0eac8f98e504b Task-number: QTCREATORBUG-14394 Reviewed-by: Eike Ziller <eike.ziller@theqtcompany.com>
Diffstat (limited to 'src/plugins/projectexplorer/projecttree.h')
-rw-r--r--src/plugins/projectexplorer/projecttree.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/plugins/projectexplorer/projecttree.h b/src/plugins/projectexplorer/projecttree.h
index 3f28618a0f..5f74f15718 100644
--- a/src/plugins/projectexplorer/projecttree.h
+++ b/src/plugins/projectexplorer/projecttree.h
@@ -130,7 +130,7 @@ public: // for nodes to emit signals, do not call unless you are a node
void collapseAll();
private:
- void updateDefaultLocationForNewFiles();
+ void sessionChanged();
void focusChanged();
void updateFromProjectTreeWidget(Internal::ProjectTreeWidget *widget);
void documentManagerCurrentFileChanged();