From 8f88bf37aa6f81d097ce9b99fc8fbe64b29a8ab7 Mon Sep 17 00:00:00 2001 From: Johannes Schultz Date: Thu, 21 Nov 2024 19:57:20 +0000 Subject: [PATCH] Merged revision(s) 22257 from trunk/OpenMPT: [Fix] Key Config: When changing a shortcut via a search that had results in multiple contexts, a wrong context could be assigned to the shortcut. ........ git-svn-id: https://source.openmpt.org/svn/openmpt/branches/OpenMPT-1.31@22258 56274372-70c3-4bfc-bfc3-4c3a0b034d27 --- mptrack/KeyConfigDlg.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mptrack/KeyConfigDlg.cpp b/mptrack/KeyConfigDlg.cpp index f85479d87f0..5c35f8d9ba6 100644 --- a/mptrack/KeyConfigDlg.cpp +++ b/mptrack/KeyConfigDlg.cpp @@ -726,7 +726,7 @@ void COptionsKeyboard::OnSetKeyChoice() if(m_bKeyUp.GetCheck() != BST_UNCHECKED) event |= kKeyEventUp; - KeyCombination kc((commandCategories[m_curCategory]).id, m_eCustHotKey.mod, m_eCustHotKey.code, event); + KeyCombination kc((commandCategories[GetCategoryFromCommandID(cmd)]).id, m_eCustHotKey.mod, m_eCustHotKey.code, event); //detect invalid input if(!kc.KeyCode()) {