summaryrefslogtreecommitdiff
path: root/internal/tui/flamegraph/model.go
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2026-05-26 22:48:54 +0300
committerPaul Buetow <paul@buetow.org>2026-05-26 22:48:54 +0300
commitff8ef868472dd3b359c03e4ff9163bf2d113e0bf (patch)
tree26690368120ad431956f9a1803b90829e78786e3 /internal/tui/flamegraph/model.go
parentfb5a9c1f5c99559cb013a6ff396eb56a7d1f7be6 (diff)
vo: fix flamegraph click mapping for expanded leaf rows
Diffstat (limited to 'internal/tui/flamegraph/model.go')
-rw-r--r--internal/tui/flamegraph/model.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/internal/tui/flamegraph/model.go b/internal/tui/flamegraph/model.go
index fe9b73b..81fcb7b 100644
--- a/internal/tui/flamegraph/model.go
+++ b/internal/tui/flamegraph/model.go
@@ -1088,12 +1088,12 @@ func (m Model) rootSnapshotPath() string {
// frameIndexAt delegates to the FrameAnimator package-level helper to convert
// terminal coordinates (x, y) to a frame index, accounting for UI chrome.
func (m Model) frameIndexAt(x, y int) int {
- return frameIndexAt(m.frames, x, y, m.width, m.height, m.showHelp)
+ return frameIndexAt(m.frames, x, y, m.width, m.height, m.showHelp, strings.TrimSpace(m.heightField) != "")
}
// frameCoordToTargetRow delegates to the FrameAnimator package-level helper.
func (m Model) frameCoordToTargetRow(dataRow, availableRows int) int {
- return frameCoordToTargetRow(m.frames, dataRow, availableRows)
+ return frameCoordToTargetRow(m.frames, dataRow, availableRows, strings.TrimSpace(m.heightField) != "")
}
func (m Model) withZoomLineage(frames []tuiFrame) []tuiFrame {