forked from qt-creator/qt-creator
Limit scope of uses of RunControl::runConfiguration()
Change-Id: Iccd9c0ce869060367db606b3c338bf21b2299548 Reviewed-by: Ulf Hermann <ulf.hermann@qt.io>
This commit is contained in:
@@ -122,10 +122,8 @@ void BareMetalDebugSupport::start()
|
||||
|
||||
Runnable inferior;
|
||||
inferior.executable = bin;
|
||||
if (auto aspect = runControl()->aspect<ArgumentsAspect>()) {
|
||||
const auto rc = runControl()->runConfiguration();
|
||||
inferior.commandLineArguments = aspect->arguments(rc->macroExpander());
|
||||
}
|
||||
if (auto aspect = runControl()->aspect<ArgumentsAspect>())
|
||||
inferior.commandLineArguments = aspect->arguments(runControl()->macroExpander());
|
||||
setInferior(inferior);
|
||||
setSymbolFile(bin);
|
||||
setStartMode(AttachToRemoteServer);
|
||||
|
@@ -74,14 +74,14 @@ QmlPreviewRunner::QmlPreviewRunner(ProjectExplorer::RunControl *runControl,
|
||||
});
|
||||
|
||||
connect(m_connectionManager.data(), &Internal::QmlPreviewConnectionManager::restart,
|
||||
runControl, [runControl, this]() {
|
||||
runControl, [runControl]() {
|
||||
if (!runControl->isRunning())
|
||||
return;
|
||||
|
||||
ProjectExplorer::RunConfiguration *runConfig = runControl->runConfiguration();
|
||||
connect(runControl, &ProjectExplorer::RunControl::stopped, runConfig, [runConfig](){
|
||||
connect(runControl, &ProjectExplorer::RunControl::stopped, runControl, [runControl]() {
|
||||
ProjectExplorer::ProjectExplorerPlugin::runRunConfiguration(
|
||||
runConfig, ProjectExplorer::Constants::QML_PREVIEW_RUN_MODE, true);
|
||||
runControl->runConfiguration(),
|
||||
ProjectExplorer::Constants::QML_PREVIEW_RUN_MODE, true);
|
||||
});
|
||||
|
||||
runControl->initiateStop();
|
||||
|
Reference in New Issue
Block a user