Symbian: Show debugger language chooser in run settings

This commit is contained in:
Kai Koehne
2011-02-14 13:36:39 +01:00
parent e7d09866a2
commit 5c3f677fe6
2 changed files with 35 additions and 0 deletions

View File

@@ -34,6 +34,7 @@
#include "s60devicerunconfigurationwidget.h" #include "s60devicerunconfigurationwidget.h"
#include "s60devicerunconfiguration.h" #include "s60devicerunconfiguration.h"
#include <utils/debuggerlanguagechooser.h>
#include <utils/detailswidget.h> #include <utils/detailswidget.h>
#include <QtGui/QLineEdit> #include <QtGui/QLineEdit>
@@ -69,12 +70,26 @@ S60DeviceRunConfigurationWidget::S60DeviceRunConfigurationWidget(
detailsBoxLayout->addLayout(formLayout); detailsBoxLayout->addLayout(formLayout);
formLayout->addRow(tr("Arguments:"), m_argumentsLineEdit); formLayout->addRow(tr("Arguments:"), m_argumentsLineEdit);
m_debuggerLanguageChooser = new Utils::DebuggerLanguageChooser(this);
formLayout->addRow(tr("Debugger:"), m_debuggerLanguageChooser);
m_debuggerLanguageChooser->setCppChecked(m_runConfiguration->useCppDebugger());
m_debuggerLanguageChooser->setQmlChecked(m_runConfiguration->useQmlDebugger());
m_debuggerLanguageChooser->setQmlDebugServerPort(m_runConfiguration->qmlDebugServerPort());
connect(m_argumentsLineEdit, SIGNAL(textEdited(QString)), connect(m_argumentsLineEdit, SIGNAL(textEdited(QString)),
this, SLOT(argumentsEdited(QString))); this, SLOT(argumentsEdited(QString)));
connect(m_runConfiguration, SIGNAL(isEnabledChanged(bool)), connect(m_runConfiguration, SIGNAL(isEnabledChanged(bool)),
this, SLOT(runConfigurationEnabledChange(bool))); this, SLOT(runConfigurationEnabledChange(bool)));
connect(m_debuggerLanguageChooser, SIGNAL(cppLanguageToggled(bool)),
this, SLOT(useCppDebuggerToggled(bool)));
connect(m_debuggerLanguageChooser, SIGNAL(qmlLanguageToggled(bool)),
this, SLOT(useQmlDebuggerToggled(bool)));
connect(m_debuggerLanguageChooser, SIGNAL(qmlDebugServerPortChanged(uint)),
this, SLOT(qmlDebugServerPortChanged(uint)));
setEnabled(m_runConfiguration->isEnabled()); setEnabled(m_runConfiguration->isEnabled());
} }
@@ -88,5 +103,20 @@ void S60DeviceRunConfigurationWidget::runConfigurationEnabledChange(bool enabled
setEnabled(enabled); setEnabled(enabled);
} }
void S60DeviceRunConfigurationWidget::useCppDebuggerToggled(bool enabled)
{
m_runConfiguration->setUseCppDebugger(enabled);
}
void S60DeviceRunConfigurationWidget::useQmlDebuggerToggled(bool enabled)
{
m_runConfiguration->setUseQmlDebugger(enabled);
}
void S60DeviceRunConfigurationWidget::qmlDebugServerPortChanged(uint port)
{
m_runConfiguration->setQmlDebugServerPort(port);
}
} // namespace Internal } // namespace Internal
} // namespace Qt4ProjectManager } // namespace Qt4ProjectManager

View File

@@ -42,6 +42,7 @@ QT_END_NAMESPACE
namespace Utils { namespace Utils {
class DetailsWidget; class DetailsWidget;
class DebuggerLanguageChooser;
} }
namespace Qt4ProjectManager { namespace Qt4ProjectManager {
@@ -58,10 +59,14 @@ public:
private slots: private slots:
void argumentsEdited(const QString &text); void argumentsEdited(const QString &text);
void runConfigurationEnabledChange(bool enabled); void runConfigurationEnabledChange(bool enabled);
void useCppDebuggerToggled(bool);
void useQmlDebuggerToggled(bool);
void qmlDebugServerPortChanged(uint);
private: private:
S60DeviceRunConfiguration *m_runConfiguration; S60DeviceRunConfiguration *m_runConfiguration;
Utils::DetailsWidget *m_detailsWidget; Utils::DetailsWidget *m_detailsWidget;
Utils::DebuggerLanguageChooser *m_debuggerLanguageChooser;
QLineEdit *m_argumentsLineEdit; QLineEdit *m_argumentsLineEdit;
}; };