WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   General Authoring Discussion (https://www.wowinterface.com/forums/forumdisplay.php?f=20)
-   -   How to hook LibActionButton? (https://www.wowinterface.com/forums/showthread.php?t=56631)

drenos 09-03-18 02:57 AM

How to hook LibActionButton?
 
I have a small addon that allows setting key bindings for spells using a lua file, and an accompanying addon that places these keys as text on action bar buttons.

It was a very long time since I wrote this, so I don't remember all the details but at the moment it uses `hooksecurefunc("ActionButton_Update")` to do its magic.

The code is here - https://github.com/kesor/wow-binder-...nderLabels.lua

Unfortunately, this does not work with ElvUI and/or other action bar addons, most probably because these use LibActionButton.

Can someone please help me figure out how to do the same thing that works with the original action bar buttons, but hooking on some function of LibActionButton?

Thank you!

drenos 09-03-18 08:15 AM

After many hours of trial and error and various inspection techniques and reading LibActionButton's code, I finally made it work ... :banana:

For those interested, see change in this PR https://github.com/kesor/wow-binder-labels/pull/1


All times are GMT -6. The time now is 03:48 AM.

vBulletin © 2024, Jelsoft Enterprises Ltd
© 2004 - 2022 MMOUI