Skip to content

Commit 28a3a96

Browse files
chopperbrianoclaude
andcommitted
Dashboard: hide [F] immediately after press and after fix confirmed (win.20)
The [F] Fix IPFS key was sticking around in the help bar after the user pressed it, because the hide condition only checked "IPFS is already announcing directly". Between pressing F and the next poll confirming the fix, the key remained visible and could be pressed again uselessly. Tighten the showFixKey condition to also hide it when _ipfsAnnounceFixApplied is true. So [F] disappears: - Immediately after press (fix in flight / awaiting IPFS restart) - Permanently once the direct address is seen in /id - Any time the fixable condition isn't currently present The hint line above the separator still communicates what's happening ("Waiting for IPFS Desktop restart..."), so the user knows the action is in progress even though the hotkey is gone. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 6525900 commit 28a3a96

2 files changed

Lines changed: 11 additions & 3 deletions

File tree

CMakeLists.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ SET(PATCH_VERSION 0)
4040
SET(SO_VERSION 0)
4141

4242
# Windows port build number (increment for each Windows-specific release)
43-
SET(WIN_BUILD 19)
43+
SET(WIN_BUILD 20)
4444

4545
# Add source directory
4646
include_directories(src)

src/ConsoleDashboard.cpp

Lines changed: 10 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -522,11 +522,19 @@ void ConsoleDashboard::render() {
522522
}
523523

524524
// Help bar (cursor is already on the right line after the \n above)
525-
// Include [F] only when the fix is applicable, to avoid cluttering the UI.
525+
// [F] is shown ONLY when the fix is actionable right now:
526+
// - initial diagnosis completed
527+
// - IPFS is not already announcing a direct address
528+
// - port 4001 is externally reachable (otherwise fix would make it worse)
529+
// - the user hasn't already pressed F (in-flight or awaiting restart)
530+
// Once any of those stops being true, [F] disappears from the help bar.
526531
bool showFixKey = false;
527532
{
528533
std::lock_guard<std::mutex> lock(_ipfsAnnounceMutex);
529-
showFixKey = !_ipfsAnnouncedDirectly && _ipfsPort4001Open && _ipfsAnnounceChecked;
534+
showFixKey = _ipfsAnnounceChecked &&
535+
!_ipfsAnnouncedDirectly &&
536+
!_ipfsAnnounceFixApplied &&
537+
_ipfsPort4001Open;
530538
}
531539
out << ERASE_LINE << DIM << " [Q] Quit [A] Assets [P] Ports [L] Log Level";
532540
if (showFixKey) {

0 commit comments

Comments
 (0)