Debugger: Shift some perspective related API to the perspective class

Also, use QString uniformly for the (now rarely used) perspective ids.

Change-Id: I682062e7d179d0fcfd309e7714713bd1218bd8bb
Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
This commit is contained in:
hjk
2018-08-22 10:53:34 +02:00
parent aca14a36e9
commit e6e38df436
8 changed files with 37 additions and 52 deletions

View File

@@ -547,7 +547,7 @@ ProjectExplorer::RunControl *QmlProfilerTool::attachToWaitingApplication()
serverUrl.setHost(toolControl.host());
serverUrl.setPort(port);
Debugger::selectPerspective(Constants::QmlProfilerPerspectiveId);
d->m_viewContainer->perspective()->select();
auto runConfig = RunConfiguration::startupRunConfiguration();
auto runControl = new RunControl(runConfig, ProjectExplorer::Constants::QML_PROFILER_RUN_MODE);
@@ -616,7 +616,7 @@ void QmlProfilerTool::showLoadDialog()
if (!checkForUnsavedNotes())
return;
Debugger::selectPerspective(QmlProfilerPerspectiveId);
d->m_viewContainer->perspective()->select();
QLatin1String tFile(QtdFileExtension);
QLatin1String zFile(QztFileExtension);
@@ -640,8 +640,8 @@ void QmlProfilerTool::profileStartupProject()
{
if (!prepareTool())
return;
Debugger::selectPerspective(Constants::QmlProfilerPerspectiveId);
ProjectExplorerPlugin::runStartupProject(ProjectExplorer::Constants::QML_PROFILER_RUN_MODE);
d->m_viewContainer->perspective()->select();
ProjectExplorerPlugin::runStartupProject(ProjectExplorer::Constants::QML_PROFILER_RUN_MODE);
}
QAction *QmlProfilerTool::startAction() const