Commit 544aea1a authored by hjk's avatar hjk
Browse files

debugger: watcher creation revisited

parent e2ef47bc
...@@ -158,7 +158,7 @@ DebuggerSettings *DebuggerSettings::instance() ...@@ -158,7 +158,7 @@ DebuggerSettings *DebuggerSettings::instance()
instance->insertItem(UseDebuggingHelpers, item); instance->insertItem(UseDebuggingHelpers, item);
item->setDefaultValue(true); item->setDefaultValue(true);
item->setSettingsKey("DebugMode", "UseDebuggingHelper"); item->setSettingsKey("DebugMode", "UseDebuggingHelper");
item->setText(tr("Use Debugging Helper")); item->setText(tr("Use debugging helper"));
item->setCheckable(true); item->setCheckable(true);
item->setDefaultValue(true); item->setDefaultValue(true);
......
...@@ -932,7 +932,6 @@ QString WatchHandler::watcherName(const QString &exp) ...@@ -932,7 +932,6 @@ QString WatchHandler::watcherName(const QString &exp)
void WatchHandler::watchExpression(const QString &exp) void WatchHandler::watchExpression(const QString &exp)
{ {
// FIXME: 'exp' can contain illegal characters // FIXME: 'exp' can contain illegal characters
//MODEL_DEBUG("WATCH: " << exp);
m_watchers[exp] = watcherCounter++; m_watchers[exp] = watcherCounter++;
WatchData data; WatchData data;
data.exp = exp; data.exp = exp;
......
...@@ -96,7 +96,7 @@ public: ...@@ -96,7 +96,7 @@ public:
} else if (index.column() == 0) { } else if (index.column() == 0) {
// the watcher name column // the watcher name column
theDebuggerAction(RemoveWatchExpression)->trigger(exp); theDebuggerAction(RemoveWatchExpression)->trigger(exp);
theDebuggerAction(WatchExpression)->trigger(lineEdit->text()); theDebuggerAction(WatchExpression)->trigger(value);
} }
} }
...@@ -175,8 +175,6 @@ void WatchWindow::contextMenuEvent(QContextMenuEvent *ev) ...@@ -175,8 +175,6 @@ void WatchWindow::contextMenuEvent(QContextMenuEvent *ev)
QModelIndex idx = indexAt(ev->pos()); QModelIndex idx = indexAt(ev->pos());
QModelIndex mi0 = idx.sibling(idx.row(), 0); QModelIndex mi0 = idx.sibling(idx.row(), 0);
QString exp = model()->data(mi0).toString(); QString exp = model()->data(mi0).toString();
QModelIndex mi1 = idx.sibling(idx.row(), 0);
QString value = model()->data(mi1).toString();
menu.addSeparator(); menu.addSeparator();
int type = (m_type == LocalsType) ? WatchExpression : RemoveWatchExpression; int type = (m_type == LocalsType) ? WatchExpression : RemoveWatchExpression;
......
Supports Markdown
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