Wireshark 4.7.0
The Wireshark network protocol analyzer
Loading...
Searching...
No Matches
Public Member Functions | List of all members
LuaDebuggerChangeHighlightTracker Class Reference

"Value changed since last pause" highlighter for the Watch and Variables trees. More...

#include <lua_debugger_utils.h>

Public Member Functions

void refreshChangedValueBrushes (QTreeView *watchTree, QWidget *paletteFallback)
 
void snapshotBaselinesOnPauseEntry ()
 
void updatePauseEntryFrameIdentity ()
 
void setPauseEntryStackLevel (int level)
 
void setPauseEntryRefresh (bool active)
 Toggle the pause-entry refresh flag. The dialog turns it on for the duration of the pause-entry refresh sequence (so changed rows get the one-shot row flash on top of the persistent bold accent) and off again afterwards.

 
void applyChangedVisuals (QObject *timerOwner, QStandardItem *anchor, bool changed)
 Stamp the anchor row with the change visuals; isPauseEntryRefresh_ is consulted internally so callers no longer have to thread it through.
 
void clearAllChangeBaselines ()
 
void clearWatchBaselines ()
 Wipe watch-side baselines (root + child value maps and visited-parent sets). Variables-tree maps are kept; they are not tied to watch specs and remain valid across watch list rebuilds.
 
void clearChangeBaselinesForWatchSpec (const QString &spec)
 
void pruneChangeBaselinesToLiveWatchSpecs (QStandardItemModel *watchModel)
 
bool changeHighlightAllowed (int stackSelectionLevel) const
 
bool observeWatchRootValue (const QString &rootKey, const QString &value)
 Record the latest value for a watch root keyed by the composite rootKey. Returns true if the new value differs from the previous baseline (a brand-new row never reads as changed).
 
bool observeWatchChildParent (const QString &rootKey, const QString &parentPath)
 Record parentPath as a visited parent in the watch-child visited-parents set keyed by rootKey. Returns true if the same parent was visited at the previous pause; false on first-time expansion. Used as the flashNew gate for child rows.
 
bool observeWatchChildValue (const QString &rootKey, const QString &childPath, const QString &value, bool parentVisited)
 Record the latest value for a watch-child row at rootKey/childPath. parentVisited is the result of observeWatchChildParent for the matching parent and gates the "child appeared since last pause" branch.
 
bool observeVariablesParent (const QString &parentKey)
 Variables-tree counterpart to observeWatchChildParent.
 
bool observeVariablesValue (const QString &variablesKey, const QString &value, bool parentVisited)
 Variables-tree counterpart to observeWatchChildValue.
 

Detailed Description

"Value changed since last pause" highlighter for the Watch and Variables trees.

Owns five related concerns:

Callers do not poke at the baseline / current hashes directly; the observe* helpers update the current map and return whether the new value differs from baseline (also taking the parent-visited gate into account where appropriate). Then applyChangedVisuals stamps the row with the matching visuals using the current pause-entry flag.

That contract intentionally hides isPauseEntryRefresh_ and the value maps from the rest of the dialog so the controllers stay focused on "which row, which value" instead of "which map, which gate".

Member Function Documentation

◆ applyChangedVisuals()

void LuaDebuggerChangeHighlightTracker::applyChangedVisuals ( QObject *  timerOwner,
QStandardItem *  anchor,
bool  changed 
)

Stamp the anchor row with the change visuals; isPauseEntryRefresh_ is consulted internally so callers no longer have to thread it through.

Parameters
timerOwnerReceives flash-clear timers.
anchorAny cell in the row to stamp; the helper walks sibling cells in the same row.
changedTrue if the value differs from baseline (typically obtained from one of the observe* helpers).

The documentation for this class was generated from the following files: