fix(console): RPC command-reference modal audit fixes
- Clicking a command now actually closes the modal. It called ImGui::CloseCurrentPopup(), a no-op here (BeginOverlayDialog is Begin/ BeginChild, not an ImGui popup), so the picker stayed open covering the input and the insert looked like it did nothing. Set show_commands_popup_=false. - Search filter is now a member cleared when the modal opens, so it isn't stale on reopen after an outside-click / command-click dismiss (was reset only by the Close button). - Esc dismisses the modal (this overlay has no built-in Esc handling), and the search box auto-focuses on open so the user can type immediately. - Scale the 2-vs-3 column breakpoint (cmd-min-width) by dpiScale() — it was a logical-px threshold compared against a physical-px available width. - Give each category's table a unique ImGui id (##cmdsN) instead of sharing "##cmds", and translate the 7 category names (Control/Network/... — command descriptions stay English) into all 8 languages; CJK subset rebuilt (+2). (Investigated but rejected: the command-name blue was flagged as low-contrast on light skins, but the modal card is a dark glass panel on every theme, so the original color is correct — verified by rendering marble/light/color-pop-light.) Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
This commit is contained in:
@@ -185,6 +185,7 @@ private:
|
||||
|
||||
// Commands popup
|
||||
bool show_commands_popup_ = false;
|
||||
char command_search_[128] = {0}; // RPC-reference search filter (cleared when the modal opens)
|
||||
};
|
||||
|
||||
} // namespace ui
|
||||
|
||||
Reference in New Issue
Block a user