Skip to content

Commit

Permalink
Tab to toggle focus between addresses and scratchpad
Browse files Browse the repository at this point in the history
  • Loading branch information
Willy-JL committed Feb 24, 2025
1 parent fffdf61 commit 28c0b69
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 5 deletions.
6 changes: 3 additions & 3 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,13 +7,13 @@
- Type process name
- Press Enter, select with Arrows, press Enter
- Ctrl+F to focus Value field, type search Value
- Use Tab and Arrows to navigate and configure other options
- Use Arrows to navigate and configure other options
- Ctrl+Enter to search
- Ctrl+Space to stop Search, Ctrl+Z to undo/reset search
- Ctrl+A to focus Addresses list
- Ctrl+A or Tab to focus Addresses list
- Arrows to navigate Addresses, Shift to select multiple
- Enter to add to Scratchpad
- Ctrl+S to focus Scratchpad
- Ctrl+S or Tab to focus Scratchpad
- Arrows to navigate Scratchpad, Shift to select multiple
- Enter to set value
- Delete to remove from Scratchpad
Expand Down
8 changes: 6 additions & 2 deletions src/gui/window.c
Original file line number Diff line number Diff line change
Expand Up @@ -482,7 +482,9 @@ static void gui_window_draw_addresses_pane(Gui* gui, ImVec2 size) {
if(clip_i == last_focused) {
if(ImGui_Shortcut(
ImGuiMod_Ctrl | ImGuiKey_A,
ImGuiInputFlags_RouteGlobal)) {
ImGuiInputFlags_RouteGlobal) ||
(!ImGui_IsWindowFocused(ImGuiFocusedFlags_None) &&
ImGui_Shortcut(ImGuiKey_Tab, ImGuiInputFlags_RouteGlobal))) {
ImGui_SetKeyboardFocusHere();
ImGui_SetNavCursorVisible(true);
}
Expand Down Expand Up @@ -1079,7 +1081,9 @@ static void gui_window_draw_scratchpad_pane(Gui* gui, ImVec2 size) {
if(clip_i == last_focused) {
if(ImGui_Shortcut(
ImGuiMod_Ctrl | ImGuiKey_S,
ImGuiInputFlags_RouteGlobal)) {
ImGuiInputFlags_RouteGlobal) ||
(!ImGui_IsWindowFocused(ImGuiFocusedFlags_None) &&
ImGui_Shortcut(ImGuiKey_Tab, ImGuiInputFlags_RouteGlobal))) {
ImGui_SetKeyboardFocusHere();
ImGui_SetNavCursorVisible(true);
}
Expand Down

0 comments on commit 28c0b69

Please sign in to comment.