Files
benilla-octo/crates
gromandClaude Opus 5 5ed9dded4c map: the Continent and Zone pickers were blank on the first map of a session
The realm's `WorldMapFrame.xml` fills them from exactly one place: the Zone
dropdown's `<OnEvent>` on `WORLD_MAP_UPDATE` (:321), which re-runs both
pickers' initialisers and then the two `WorldMap_Update*DropDownText`
functions. That dropdown registers the event in its own `<OnShow>` (:318 —
the realm commented the `OnLoad` out and moved it there), while
`WorldMapFrame`'s own `<OnShow>` fires it through `SetMapToCurrentZone()`
(:711), and a parent's OnShow runs before its children's. So the inline event
landed in a gap where its only listener did not exist yet. Measured through the
addon harness: the Zone dropdown answers `IsEventRegistered` nil before the
open and 1 immediately after, and the pickers come up blank on the first map
and correct on the second — which is what grom's recording shows, blank over
Dun Morogh and filled over Elwynn later in the same clip.

`SetMapToCurrentZone` now queues a second `WORLD_MAP_UPDATE` on the deferred
lane as well as firing the inline one. The inline fire stays: it is what
repaints the detail tiles inside the OnShow rather than a frame later (the
world-map flash). Only this verb doubles up, and only this verb needs to —
`SetMapZoom` is a click on a map that is already open.

The first attempt at this was reverted and the reason is in the test's own
comment: its pin opened the real map on the shipped interface and passed with
*and* without the fix, because the stock ordering happens to be fine and the
symptom needs the addons. The pin that replaced it asserts the engine half
directly — a handler that registers after `SetMapToCurrentZone` returns still
receives the event — and answers 0 without the change and 1 with it.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01SgstFWtn1RxEJ5kVrpgYwn
2026-11-02 21:57:07 -07:00
..