Debugger: Add VariableSupport to some text fields

Change-Id: Iba1e7d2eeb49600a9952c369f66187384aa8cbf2
Reviewed-by: hjk <hjk121@nokiamail.com>
This commit is contained in:
hjk
2014-06-05 17:49:51 +02:00
parent 7d45a1a1c5
commit e744649456
2 changed files with 12 additions and 1 deletions

View File

@@ -3376,7 +3376,8 @@ bool DebuggerPluginPrivate::boolSetting(int code) const
QString DebuggerPluginPrivate::stringSetting(int code) const
{
return m_debuggerSettings->item(code)->value().toString();
QString raw = m_debuggerSettings->item(code)->value().toString();
return VariableManager::expandedString(raw);
}
QStringList DebuggerPluginPrivate::stringListSetting(int code) const

View File

@@ -34,6 +34,7 @@
#include <debugger/debuggerinternalconstants.h>
#include <coreplugin/icore.h>
#include <coreplugin/variablechooser.h>
#include <QCheckBox>
#include <QCoreApplication>
@@ -43,6 +44,9 @@
#include <QSpinBox>
#include <QTextEdit>
using namespace Core;
namespace Debugger {
namespace Internal {
@@ -90,6 +94,8 @@ public:
GdbOptionsPageWidget::GdbOptionsPageWidget(QWidget *parent)
: QWidget(parent)
{
(void) new VariableChooser(this);
groupBoxGeneral = new QGroupBox(this);
groupBoxGeneral->setTitle(GdbOptionsPage::tr("General"));
@@ -241,6 +247,10 @@ GdbOptionsPageWidget::GdbOptionsPageWidget(QWidget *parent)
"Matching regular expression: "));
*/
VariableChooser::addVariableSupport(textEditCustomDumperCommands);
VariableChooser::addVariableSupport(textEditPostAttachCommands);
VariableChooser::addVariableSupport(textEditStartupCommands);
QFormLayout *formLayout = new QFormLayout(groupBoxGeneral);
formLayout->addRow(labelGdbWatchdogTimeout, spinBoxGdbWatchdogTimeout);
formLayout->addRow(checkBoxSkipKnownFrames);