Skip to content

Keep Blizzard menus out of the gamepad UI (SetPreferredGamepadInteractTarget taint) - #203

Merged
Wuild merged 2 commits into
Wuild:masterfrom
Ironship:fix/gamepad-menu-taint
Nov 13, 2026
Merged

Wuild merged 2 commits into
Wuild:masterfrom
Ironship:fix/gamepad-menu-taint

Conversation

@Ironship

@Ironship Ironship commented Nov 13, 2026 •

Copy link
Copy Markdown
Contributor

Addresses #197 (ADDON_ACTION_FORBIDDEN for SetPreferredGamepadInteractTarget() in the gamepad UI).

Cause

In WoW Forever's gamepad UI, GatherLite opened three Blizzard dropdown menus from its own click handlers: the minimap button's tracking menu, the world map button's tracking menu and the minimap tracker chooser. A Blizzard menu registers its controller bindings when it opens, so with this addon on the stack those bindings are written by addon code. Closing the menu later makes Blizzard's binding stack (InputBindingManager:RemoveSet -> GamepadMainActionBarFrameMixin:UpdateInteractIcons) call the protected SetPreferredGamepadInteractTarget(), which the client blames on GatherLite. Controller input then stays broken until /reload. The traces in #197 end exactly there (Menu.lua CloseMenus -> FrameControlsManager -> RemoveSet).

The window's own controller input already stays out of Blizzard's binding stack (docs/window-navigation.md); the menus were the remaining path in.

Change

In the gamepad UI only (InputUtil.IsGamepadUIEnabled() == true, checked on every call):

  • The minimap and world map tracking shortcuts open the matching settings category of the GatherLite window (the per-map tracking filters live there). Window:ShowSettings takes an optional category.
  • The minimap tracker reminder, when two or more trackers are learned, enables the first tracker the minimap filters show instead of opening a choice menu. The native tracking menu still switches it.
  • The minimap button's right click no longer calls Blizzard's menu manager.
  • The window's breadcrumb arrows (Blizzard DropdownButtons) ignore the mouse, so they cannot open a Blizzard menu; the controller keeps using the addon-owned breadcrumb menu.

Mouse and keyboard play is unchanged.

Checks

tools/test_tracking.lua, tools/test_gathering_tracking.lua and tools/test_routes.lua cover the gamepad UI (no Blizzard menu, no menu manager call, right settings category, first filtered-in tracker, breadcrumb arrows) and the unchanged mouse and keyboard UI. The new cases fail without the change. test_map_hover, test_openmap and test_compat still pass (run under Lua 5.1).

In Forever's gamepad UI the tracking menus (minimap button, world map
button) and the minimap tracker chooser were Blizzard dropdowns opened
from GatherLite's own click handlers. Their controller bindings are then
registered from addon code, and closing the menu later makes Blizzard's
binding stack call SetPreferredGamepadInteractTarget() blamed on
GatherLite: ADDON_ACTION_FORBIDDEN, and controller input stays broken
until /reload (Wuild#197).

In the gamepad UI the tracking shortcuts now open the matching settings
category of the GatherLite window (new optional argument of
Window:ShowSettings), the minimap tracker reminder enables the first
tracker the minimap filters show instead of opening a menu, and the
minimap button's right click no longer calls Blizzard's menu manager.
Mouse and keyboard play is unchanged.
The window's breadcrumb arrows are Blizzard DropdownButtons. Clicking one
with the mouse in the gamepad UI opened a Blizzard menu from an addon-owned
button, the same taint path as the tracking menus. The controller already
opens the addon-owned menu, so the arrows now ignore the mouse while the
gamepad UI is active and keep the native dropdowns otherwise.
@Wuild

Wuild commented Nov 13, 2026

Copy link
Copy Markdown
Owner

Unfortunatly i dont have access to a controller, so please test and verify this.

@Ironship

Copy link
Copy Markdown
Contributor Author

@Wuild just tested in the game. Fix confirmed

@Wuild
Wuild merged commit 44e2f29 into Wuild:master Nov 13, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants