ProjectExplorer: Rename ProjectTree::findCurrentNode to currentNode

For consistency, it's straight forwards access, similar to
currentProject, not much to search and find.

Change-Id: I7ce696bdc24b6a8713d6f11e02443a6f94c605f6
Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
hjk
2019-04-30 12:58:33 +02:00
parent 28de30df18
commit a5148b5363
13 changed files with 47 additions and 47 deletions

View File

@@ -283,7 +283,7 @@ void QbsProjectManagerPlugin::projectWasAdded(Project *project)
void QbsProjectManagerPlugin::updateContextActions()
{
auto project = qobject_cast<Internal::QbsProject *>(ProjectTree::currentProject());
const Node *node = ProjectTree::findCurrentNode();
const Node *node = ProjectTree::currentNode();
bool isEnabled = !BuildManager::isBuilding(project)
&& project && !project->isParsing()
&& node && node->isEnabled();
@@ -375,7 +375,7 @@ void QbsProjectManagerPlugin::projectChanged()
void QbsProjectManagerPlugin::buildFileContextMenu()
{
const Node *node = ProjectTree::findCurrentNode();
const Node *node = ProjectTree::currentNode();
QTC_ASSERT(node, return);
auto project = dynamic_cast<QbsProject *>(ProjectTree::currentProject());
QTC_ASSERT(project, return);
@@ -412,7 +412,7 @@ void QbsProjectManagerPlugin::rebuildProductContextMenu()
void QbsProjectManagerPlugin::runStepsForProductContextMenu(const QList<Core::Id> &stepTypes)
{
const Node *node = ProjectTree::findCurrentNode();
const Node *node = ProjectTree::currentNode();
QTC_ASSERT(node, return);
auto project = dynamic_cast<QbsProject *>(ProjectTree::currentProject());
QTC_ASSERT(project, return);
@@ -477,7 +477,7 @@ void QbsProjectManagerPlugin::rebuildSubprojectContextMenu()
void QbsProjectManagerPlugin::runStepsForSubprojectContextMenu(const QList<Core::Id> &stepTypes)
{
const Node *node = ProjectTree::findCurrentNode();
const Node *node = ProjectTree::currentNode();
QTC_ASSERT(node, return);
auto project = dynamic_cast<QbsProject *>(ProjectTree::currentProject());
QTC_ASSERT(project, return);