Commit 5898dc44 authored by hjk's avatar hjk Committed by hjk

debugger: make qml port spinbox supressable in debugger runconfig aspect

Change-Id: I0d6e18e393e07b101c1b429825a8897a15317034
Reviewed-by: default avatarChristian Kandeler <christian.kandeler@nokia.com>
parent 5e635593
......@@ -218,6 +218,11 @@ DebuggerRunConfigWidget::DebuggerRunConfigWidget(RunConfiguration *runConfigurat
m_useQmlDebugger->hide();
}
if (m_aspect->isQmlDebuggingSpinboxSuppressed()) {
m_debugServerPort->hide();
m_debugServerPortLabel->hide();
}
QHBoxLayout *qmlLayout = new QHBoxLayout;
qmlLayout->setMargin(0);
qmlLayout->addWidget(m_useQmlDebugger);
......
......@@ -203,14 +203,17 @@ DebuggerRunConfigurationAspect::DebuggerRunConfigurationAspect(RunConfiguration
m_useCppDebugger(true),
m_useQmlDebugger(AutoEnableQmlDebugger),
m_qmlDebugServerPort(Constants::QML_DEFAULT_DEBUG_SERVER_PORT),
m_suppressQmlDebuggingOptions(false)
m_suppressQmlDebuggingOptions(false),
m_suppressQmlDebuggingSpinbox(false)
{}
DebuggerRunConfigurationAspect::DebuggerRunConfigurationAspect(DebuggerRunConfigurationAspect *other) :
m_runConfiguration(other->m_runConfiguration),
m_useCppDebugger(other->m_useCppDebugger),
m_useQmlDebugger(other->m_useQmlDebugger),
m_qmlDebugServerPort(other->m_qmlDebugServerPort)
m_qmlDebugServerPort(other->m_qmlDebugServerPort),
m_suppressQmlDebuggingOptions(other->m_suppressQmlDebuggingOptions),
m_suppressQmlDebuggingSpinbox(other->m_suppressQmlDebuggingSpinbox)
{}
RunConfiguration *DebuggerRunConfigurationAspect::runConfiguration()
......@@ -264,11 +267,21 @@ void DebuggerRunConfigurationAspect::suppressQmlDebuggingOptions()
m_suppressQmlDebuggingOptions = true;
}
void DebuggerRunConfigurationAspect::suppressQmlDebuggingSpinbox()
{
m_suppressQmlDebuggingSpinbox = true;
}
bool DebuggerRunConfigurationAspect::areQmlDebuggingOptionsSuppressed() const
{
return m_suppressQmlDebuggingOptions;
}
bool DebuggerRunConfigurationAspect::isQmlDebuggingSpinboxSuppressed() const
{
return m_suppressQmlDebuggingSpinbox;
}
QString DebuggerRunConfigurationAspect::displayName() const
{
return tr("Debugger settings");
......
......@@ -113,7 +113,9 @@ public:
uint qmlDebugServerPort() const;
void setQmllDebugServerPort(uint port);
void suppressQmlDebuggingOptions();
void suppressQmlDebuggingSpinbox();
bool areQmlDebuggingOptionsSuppressed() const;
bool isQmlDebuggingSpinboxSuppressed() const;
RunConfiguration *runConfiguration();
signals:
......@@ -125,6 +127,7 @@ public:
QmlDebuggerStatus m_useQmlDebugger;
uint m_qmlDebugServerPort;
bool m_suppressQmlDebuggingOptions;
bool m_suppressQmlDebuggingSpinbox;
};
......
......@@ -127,6 +127,7 @@ RemoteLinuxRunConfiguration::RemoteLinuxRunConfiguration(Qt4BaseTarget *parent,
void RemoteLinuxRunConfiguration::init()
{
setDefaultDisplayName(defaultDisplayName());
debuggerAspect()->suppressQmlDebuggingSpinbox();
connect(target(),
SIGNAL(activeDeployConfigurationChanged(ProjectExplorer::DeployConfiguration*)),
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment