aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/debugger/watchhandler.cpp
diff options
context:
space:
mode:
authorhjk <[email protected]>2009-12-04 13:22:39 +0100
committerhjk <[email protected]>2009-12-04 13:22:59 +0100
commitef9db9cf79ff72fd9484cb406db84e6cbe02c4b5 (patch)
tree0bb6b1ebe887393f7d8ba0d3e79d0d6e2afcc610 /src/plugins/debugger/watchhandler.cpp
parentb0640b9a7a0162684b4ec053b21acaa2e84338ca (diff)
debugger: make 'watch' item work with new dumpers
Diffstat (limited to 'src/plugins/debugger/watchhandler.cpp')
-rw-r--r--src/plugins/debugger/watchhandler.cpp16
1 files changed, 11 insertions, 5 deletions
diff --git a/src/plugins/debugger/watchhandler.cpp b/src/plugins/debugger/watchhandler.cpp
index 86399746221..fdcae7dda21 100644
--- a/src/plugins/debugger/watchhandler.cpp
+++ b/src/plugins/debugger/watchhandler.cpp
@@ -644,7 +644,8 @@ static QString formattedValue(const WatchData &data,
bool WatchModel::canFetchMore(const QModelIndex &index) const
{
- return !m_inExtraLayoutChanged && index.isValid() && !m_fetchTriggered.contains(watchItem(index)->iname);
+ return !m_inExtraLayoutChanged && index.isValid()
+ && !m_fetchTriggered.contains(watchItem(index)->iname);
}
void WatchModel::fetchMore(const QModelIndex &index)
@@ -1389,10 +1390,9 @@ void WatchHandler::loadWatchers()
//reinitializeWatchersHelper();
}
-void WatchHandler::saveWatchers()
+QStringList WatchHandler::watchedExpressions() const
{
- //qDebug() << "SAVE WATCHERS: " << m_watchers;
- // Filter out valid watchers.
+ // Filter out invalid watchers.
QStringList watcherNames;
QHashIterator<QString, int> it(m_watcherNames);
while (it.hasNext()) {
@@ -1401,7 +1401,13 @@ void WatchHandler::saveWatchers()
if (!watcherName.isEmpty() && watcherName != watcherEditPlaceHolder())
watcherNames.push_back(watcherName);
}
- m_manager->setSessionValue("Watchers", QVariant(watcherNames));
+ return watcherNames;
+}
+
+void WatchHandler::saveWatchers()
+{
+ //qDebug() << "SAVE WATCHERS: " << m_watchers;
+ m_manager->setSessionValue("Watchers", QVariant(watchedExpressions()));
}
void WatchHandler::loadTypeFormats()