From 5f7126da458afbb4bac03b6bd5cc456f8c8da345 Mon Sep 17 00:00:00 2001 From: Toni Wilen Date: Sun, 8 Oct 2023 18:59:21 +0300 Subject: [PATCH] GUI control right dpad: don't jump to root node if no more child nodes. --- od-win32/win32gui_extra.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/od-win32/win32gui_extra.cpp b/od-win32/win32gui_extra.cpp index 5fb753bc..b11447f2 100644 --- a/od-win32/win32gui_extra.cpp +++ b/od-win32/win32gui_extra.cpp @@ -2275,7 +2275,7 @@ void gui_cursor(HWND hwnd, struct newresource *ns, int x, int y, int click) RECT r; GetWindowRect(h, &r); currres = txy; - write_log("%p %d\n", currres->nres->hwnd, currres->region); + //write_log("%p %d\n", currres->nres->hwnd, currres->region); break; } } @@ -2402,6 +2402,7 @@ void gui_cursor(HWND hwnd, struct newresource *ns, int x, int y, int click) for (;;) { next2 = TreeView_GetNextItem(h, next2, TVGN_NEXT); if (!next2) { + next = c; break; } next = TreeView_GetNextItem(h, next2, TVGN_CHILD); -- 2.47.3