forked from qt-creator/qt-creator
debugger: fix recent regression of non-persistent expanded watch items
Change-Id: Iec8b37812faca5584d268712181ffeca98ef6e8a Reviewed-by: hjk <qthjk@ovi.com>
This commit is contained in:
@@ -673,6 +673,14 @@ void WatchModel::emitDataChanged(int column, const QModelIndex &parentIndex)
|
|||||||
emitDataChanged(column, index(i, 0, parentIndex));
|
emitDataChanged(column, index(i, 0, parentIndex));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void WatchModel::invalidateAll(const QModelIndex &parentIndex)
|
||||||
|
{
|
||||||
|
QModelIndex idx1 = index(0, 0, parentIndex);
|
||||||
|
QModelIndex idx2 = index(rowCount(parentIndex) - 1, columnCount(parentIndex) - 1, parentIndex);
|
||||||
|
if (idx1.isValid() && idx2.isValid())
|
||||||
|
emit dataChanged(idx1, idx2);
|
||||||
|
}
|
||||||
|
|
||||||
// Truncate value for item view, maintaining quotes.
|
// Truncate value for item view, maintaining quotes.
|
||||||
static QString truncateValue(QString v)
|
static QString truncateValue(QString v)
|
||||||
{
|
{
|
||||||
@@ -1878,10 +1886,10 @@ void WatchHandler::resetLocation()
|
|||||||
{
|
{
|
||||||
if (m_resetLocationScheduled) {
|
if (m_resetLocationScheduled) {
|
||||||
m_resetLocationScheduled = false;
|
m_resetLocationScheduled = false;
|
||||||
m_return->reset();
|
m_return->invalidateAll();
|
||||||
m_locals->reset();
|
m_locals->invalidateAll();
|
||||||
m_watchers->reset();
|
m_watchers->invalidateAll();
|
||||||
m_tooltips->reset();
|
m_tooltips->invalidateAll();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -90,6 +90,8 @@ private:
|
|||||||
bool canFetchMore(const QModelIndex &parent) const;
|
bool canFetchMore(const QModelIndex &parent) const;
|
||||||
void fetchMore(const QModelIndex &parent);
|
void fetchMore(const QModelIndex &parent);
|
||||||
|
|
||||||
|
void invalidateAll(const QModelIndex &parentIndex = QModelIndex());
|
||||||
|
|
||||||
friend class WatchHandler;
|
friend class WatchHandler;
|
||||||
|
|
||||||
WatchItem *watchItem(const QModelIndex &) const;
|
WatchItem *watchItem(const QModelIndex &) const;
|
||||||
|
|||||||
Reference in New Issue
Block a user