forked from qt-creator/qt-creator
ProjectExplorerPlugin: Use expected_str for canRunStartupProject()
Change-Id: Iddc9abcb1b9ef02c6a8188d2eb82cc30a0ba4c22 Reviewed-by: Christian Kandeler <christian.kandeler@qt.io>
This commit is contained in:
@@ -276,11 +276,11 @@ void QmlProfilerTool::updateRunActions()
|
||||
d->m_startAction->setToolTip(Tr::tr("A QML Profiler analysis is still in progress."));
|
||||
d->m_stopAction->setEnabled(true);
|
||||
} else {
|
||||
QString tooltip = Tr::tr("Start QML Profiler analysis.");
|
||||
bool canRun = ProjectExplorerPlugin::canRunStartupProject
|
||||
(ProjectExplorer::Constants::QML_PROFILER_RUN_MODE, &tooltip);
|
||||
d->m_startAction->setToolTip(tooltip);
|
||||
d->m_startAction->setEnabled(canRun);
|
||||
const auto canRun = ProjectExplorerPlugin::canRunStartupProject(
|
||||
ProjectExplorer::Constants::QML_PROFILER_RUN_MODE);
|
||||
d->m_startAction->setToolTip(canRun ? Tr::tr("Start QML Profiler analysis.")
|
||||
: canRun.error());
|
||||
d->m_startAction->setEnabled(bool(canRun));
|
||||
d->m_stopAction->setEnabled(false);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user