MCPcopy Create free account
hub / github.com/KDE/kdevelop / slotAddWatch

Method slotAddWatch

kdevplatform/debugger/variable/variablewidget.cpp:140–158  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

138}
139
140void VariableWidget::slotAddWatch(const QString &expression)
141{
142 if (!expression.isEmpty())
143 {
144 m_watchVarEditor->addToHistory(expression);
145 qCDebug(DEBUGGER) << "Trying to add watch";
146 Variable* v = m_variablesRoot->watches()->add(expression);
147 if (v) {
148 /* For watches on structures, we really do want them to be shown
149 expanded. Except maybe for structure with custom pretty printing,
150 but will handle that later.
151 FIXME: it does not actually works now.
152 */
153 //QModelIndex index = variableCollection()->indexForItem(v, 0);
154 //varTree_->setExpanded(index, true);
155 }
156 m_watchVarEditor->clearEditText();
157 }
158}
159
160void VariableWidget::hideEvent(QHideEvent* e)
161{

Callers

nothing calls this directly

Calls 2

isEmptyMethod · 0.45
addMethod · 0.45

Tested by

no test coverage detected