forked from qt-creator/qt-creator
ProjectExplorer: Optionally show run environment in app output pane
Fixes: QTCREATORBUG-28427 Change-Id: I1022a377d3728ad5e91fa62514082110b86db9f4 Reviewed-by: hjk <hjk@qt.io> Reviewed-by: Qt CI Bot <qt_ci_bot@qt-project.org> Reviewed-by: <github-actions-qt-creator@cristianadam.eu>
This commit is contained in:
@@ -9,6 +9,7 @@
|
||||
#include <utils/environment.h>
|
||||
#include <utils/qtcassert.h>
|
||||
|
||||
#include <QCheckBox>
|
||||
#include <QComboBox>
|
||||
#include <QHBoxLayout>
|
||||
#include <QLabel>
|
||||
@@ -63,6 +64,14 @@ EnvironmentAspectWidget::EnvironmentAspectWidget(EnvironmentAspect *aspect)
|
||||
m_environmentWidget->setSizePolicy(QSizePolicy::Expanding, QSizePolicy::Expanding);
|
||||
topLayout->addWidget(m_environmentWidget);
|
||||
|
||||
if (m_aspect->isPrintOnRunAllowed()) {
|
||||
const auto printOnRunCheckBox = new QCheckBox(Tr::tr("Show in output pane when running"));
|
||||
printOnRunCheckBox->setChecked(m_aspect->isPrintOnRunEnabled());
|
||||
connect(printOnRunCheckBox, &QCheckBox::toggled,
|
||||
m_aspect, &EnvironmentAspect::setPrintOnRun);
|
||||
topLayout->addWidget(printOnRunCheckBox);
|
||||
}
|
||||
|
||||
connect(m_environmentWidget, &EnvironmentWidget::userChangesChanged,
|
||||
this, &EnvironmentAspectWidget::userChangesEdited);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user