Commit db1c21a3 authored by hjk's avatar hjk

Debugger: Make WatchDelegate less dependent on WatchView

Change-Id: I07c1c22d1dfa9323a2fed8938c4fe53d1a534e90
Reviewed-by: default avatarChristian Stenger <christian.stenger@digia.com>
parent 73158461
......@@ -90,8 +90,8 @@ const char CurrentIndex[] = "CurrentIndex";
class WatchDelegate : public QItemDelegate
{
public:
explicit WatchDelegate(WatchTreeView *parent)
: QItemDelegate(parent), m_watchWindow(parent)
explicit WatchDelegate(QObject *parent)
: QItemDelegate(parent)
{}
QWidget *createEditor(QWidget *parent, const QStyleOptionViewItem &,
......@@ -141,7 +141,7 @@ public:
return;
WatchHandler *handler = currentEngine()->watchHandler();
handler->removeData(index.data(LocalsINameRole).toByteArray());
m_watchWindow->watchExpression(value);
handler->watchExpression(value);
}
void updateEditorGeometry(QWidget *editor, const QStyleOptionViewItem &option,
......@@ -149,9 +149,6 @@ public:
{
editor->setGeometry(option.rect);
}
private:
WatchTreeView *m_watchWindow;
};
// Watch model query helpers.
......
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