diff options
author | hjk <hjk@qt.io> | 2021-01-06 11:52:37 +0100 |
---|---|---|
committer | hjk <hjk@qt.io> | 2021-01-07 12:09:40 +0000 |
commit | 111cc934fd99d4abc2b46bdab54fabf006409331 (patch) | |
tree | 28b2538188fb90abbc11ab41f78e7b27ee95b014 /src/plugins/debugger/breakhandler.h | |
parent | 41982acec318213b1fca30e18d1febda4292161f (diff) |
Debugger: Mark currently hit breakpoint in breakpoint view
Fixes: QTCREATORBUG-6999
Change-Id: I2b080de0096d1e2bc5b348666adcf4797589fe15
Reviewed-by: Christian Stenger <christian.stenger@qt.io>
Diffstat (limited to 'src/plugins/debugger/breakhandler.h')
-rw-r--r-- | src/plugins/debugger/breakhandler.h | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/plugins/debugger/breakhandler.h b/src/plugins/debugger/breakhandler.h index eee210fc89..ad334d10b8 100644 --- a/src/plugins/debugger/breakhandler.h +++ b/src/plugins/debugger/breakhandler.h @@ -39,13 +39,14 @@ namespace Utils { class ItemViewEvent; } namespace Debugger { namespace Internal { +class BreakHandler; class BreakpointItem; +class BreakpointManager; class BreakpointMarker; -class BreakHandler; class DebuggerCommand; class DebuggerEngine; -class BreakpointManager; class GlobalBreakpointMarker; +class Location; class SubBreakpointItem : public QObject, public Utils::TypedTreeItem<Utils::TreeItem, BreakpointItem> { @@ -122,7 +123,7 @@ public: QVariant data(int column, int role) const final; - QIcon icon() const; + QIcon icon(bool withLocationMarker = false) const; void setMarkerFileAndLine(const Utils::FilePath &fileName, int lineNumber); bool needsChange() const; @@ -197,6 +198,8 @@ public: const GlobalBreakpoint globalBreakpoint() const; void gotoState(BreakpointState target, BreakpointState assumedCurrent); + void setNeedsLocationMarker(bool needsLocationMarker); + private: void destroyMarker(); void updateMarker(); @@ -209,6 +212,7 @@ private: BreakpointMarker *m_marker = nullptr; QString m_responseId; //!< Breakpoint number or id assigned by or used in the debugger backend. QString m_displayName; + bool m_needsLocationMarker = false; }; using Breakpoint = QPointer<BreakpointItem>; @@ -261,6 +265,9 @@ public: void updateDisassemblerMarker(const Breakpoint &bp); void removeDisassemblerMarker(const Breakpoint &bp); + void setLocation(const Location &loc); + void resetLocation(); + private: Breakpoint findBreakpointByIndex(const QModelIndex &index) const; Breakpoints findBreakpointsByIndex(const QList<QModelIndex> &list) const; |