Skip to content

TUI: File/Network/Threads/etc detail tabs never refresh after the initial view #94

Description

@rezdm

Problem

`TuiApp::refresh_selected_details()` (src/ui/tui/tui_details_panel.cpp:8-30) only re-fetches the active tab's data when the PID changes, the tab changes, or an explicit `details_needs_refresh_` request is made. Nothing in the main loop (src/ui/tui/tui_app.cpp:193-208) sets that flag when a new snapshot arrives — the snapshot-changed branch updates `current_data_`/`view_model_` and triggers a repaint, but never touches `details_needs_refresh_`.

Compare to the GUI's `refresh_selected_details()` (src/ui/imgui/imgui_details_panel_view.cpp), which has an additional time-based trigger (`kDetailsRefreshInterval = 500ms`) that re-fetches periodically regardless of tab/pid change.

Effect: in the TUI, Network connections, open files, threads, memory maps etc. for the selected process go stale indefinitely once viewed, until the user switches tabs away and back (or presses whatever explicit refresh key exists). This is likely the most user-visible TUI bug in this batch — a selected process's Network/Files tab looks frozen even while data is clearly still being collected (system panel keeps updating).

Fix

Add the same kind of periodic re-fetch trigger the GUI has — e.g. set `details_needs_refresh_ = true` whenever the main loop picks up a new snapshot, or add an equivalent time-based interval check inside `refresh_selected_details()` itself.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions