summaryrefslogtreecommitdiff
path: root/internal/tui/msg.go
diff options
context:
space:
mode:
authorPaul Buetow <paul@buetow.org>2026-02-23 23:29:58 +0200
committerPaul Buetow <paul@buetow.org>2026-02-23 23:29:58 +0200
commite68102bc79ac26f93959c3d5676bcdca86c94623 (patch)
tree909bea2261a5076e4c8f854bedcc13802a55de0b /internal/tui/msg.go
parent72daf71f04c06660a9abf588f046a30f8b68b4a9 (diff)
tui: add shared bubbletea message types (task 302)
Diffstat (limited to 'internal/tui/msg.go')
-rw-r--r--internal/tui/msg.go24
1 files changed, 24 insertions, 0 deletions
diff --git a/internal/tui/msg.go b/internal/tui/msg.go
new file mode 100644
index 0000000..ba2ec53
--- /dev/null
+++ b/internal/tui/msg.go
@@ -0,0 +1,24 @@
+package tui
+
+import "ior/internal/statsengine"
+
+// PidSelectedMsg is emitted when the user selects a PID from the process table.
+type PidSelectedMsg struct {
+ Pid int
+}
+
+// StatsTickMsg carries a fresh immutable snapshot from the stats engine.
+type StatsTickMsg struct {
+ Snap *statsengine.Snapshot
+}
+
+// ExportRequestMsg requests an export of the current UI state.
+type ExportRequestMsg struct{}
+
+// TracingStartedMsg signals that tracing started successfully.
+type TracingStartedMsg struct{}
+
+// TracingErrorMsg reports an error while starting or running tracing.
+type TracingErrorMsg struct {
+ Err error
+}