mirror of
https://github.com/Kelsidavis/WoWee.git
synced 2026-04-17 17:43:52 +00:00
fix: fire ACTIONBAR_SLOT_CHANGED when assigning spells to action bar
setActionBarSlot (called from PickupAction/PlaceAction drag-drop and from server-driven action button updates) updated the slot data and notified the server, but never fired the Lua addon event. Action bar addons (Bartender4, Dominos) register for ACTIONBAR_SLOT_CHANGED to refresh button textures, tooltips, and cooldown state when slots change. Also fires ACTIONBAR_UPDATE_STATE for general action bar refresh.
This commit is contained in:
parent
d00ebd00a0
commit
b25dba8069
1 changed files with 5 additions and 0 deletions
|
|
@ -19327,6 +19327,11 @@ void GameHandler::setActionBarSlot(int slot, ActionBarSlot::Type type, uint32_t
|
||||||
queryItemInfo(id, 0);
|
queryItemInfo(id, 0);
|
||||||
}
|
}
|
||||||
saveCharacterConfig();
|
saveCharacterConfig();
|
||||||
|
// Notify Lua addons that the action bar changed
|
||||||
|
if (addonEventCallback_) {
|
||||||
|
addonEventCallback_("ACTIONBAR_SLOT_CHANGED", {std::to_string(slot + 1)});
|
||||||
|
addonEventCallback_("ACTIONBAR_UPDATE_STATE", {});
|
||||||
|
}
|
||||||
// Notify the server so the action bar persists across relogs.
|
// Notify the server so the action bar persists across relogs.
|
||||||
if (state == WorldState::IN_WORLD && socket) {
|
if (state == WorldState::IN_WORLD && socket) {
|
||||||
const bool classic = isClassicLikeExpansion();
|
const bool classic = isClassicLikeExpansion();
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue