fix: Menu items greyed out when they shouldn't (#2378)

Problem was that a recent commit allowed any subview window to become
the current subview with focus which also included the context menu
popup. The fix is to list all the subviews that can acquire focus so
that they are the only ones that will be detected by the menu condition.
This commit is contained in:
paxcut
2025-08-04 03:23:24 -07:00
committed by GitHub
parent 9fc9eb1425
commit 136cabedb4

View File

@@ -351,7 +351,8 @@ namespace hex::plugin::builtin {
oldHeight = height;
if (g.NavWindow != nullptr) {
std::string name = g.NavWindow->Name;
m_focusedSubWindowName = name;
if (name.contains(textEditorView) || name.contains(consoleView) || name.contains(variablesView) || name.contains(settingsView) || name.contains(virtualFilesView) || name.contains(debuggerView))
m_focusedSubWindowName = name;
}
fonts::CodeEditor().push();