mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-03-22 23:30:14 +00:00
feat: Escape key closes topmost open window before showing menu
Escape now closes UI windows in priority order (vendor, bank, trainer, who, combat log, social, talents, spellbook, quest log, character, inventory, world map) before falling through to the escape menu, matching standard WoW behavior.
This commit is contained in:
parent
f283f9eb86
commit
d6c752fba5
1 changed files with 24 additions and 1 deletions
|
|
@ -2751,7 +2751,6 @@ void GameScreen::processTargetInput(game::GameHandler& gameHandler) {
|
|||
|
||||
if (KeybindingManager::getInstance().isActionPressed(KeybindingManager::Action::TOGGLE_SETTINGS, true)) {
|
||||
if (showSettingsWindow) {
|
||||
// Close settings window if open
|
||||
showSettingsWindow = false;
|
||||
} else if (showEscapeMenu) {
|
||||
showEscapeMenu = false;
|
||||
|
|
@ -2762,6 +2761,30 @@ void GameScreen::processTargetInput(game::GameHandler& gameHandler) {
|
|||
gameHandler.closeLoot();
|
||||
} else if (gameHandler.isGossipWindowOpen()) {
|
||||
gameHandler.closeGossip();
|
||||
} else if (gameHandler.isVendorWindowOpen()) {
|
||||
gameHandler.closeVendor();
|
||||
} else if (gameHandler.isBankOpen()) {
|
||||
gameHandler.closeBank();
|
||||
} else if (gameHandler.isTrainerWindowOpen()) {
|
||||
gameHandler.closeTrainer();
|
||||
} else if (showWhoWindow_) {
|
||||
showWhoWindow_ = false;
|
||||
} else if (showCombatLog_) {
|
||||
showCombatLog_ = false;
|
||||
} else if (showSocialFrame_) {
|
||||
showSocialFrame_ = false;
|
||||
} else if (talentScreen.isOpen()) {
|
||||
talentScreen.setOpen(false);
|
||||
} else if (spellbookScreen.isOpen()) {
|
||||
spellbookScreen.setOpen(false);
|
||||
} else if (questLogScreen.isOpen()) {
|
||||
questLogScreen.setOpen(false);
|
||||
} else if (inventoryScreen.isCharacterOpen()) {
|
||||
inventoryScreen.toggleCharacter();
|
||||
} else if (inventoryScreen.isOpen()) {
|
||||
inventoryScreen.setOpen(false);
|
||||
} else if (showWorldMap_) {
|
||||
showWorldMap_ = false;
|
||||
} else {
|
||||
showEscapeMenu = true;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue