View Single Post
04-06-19, 04:35 PM   #4
elcius
A Cliff Giant
AddOn Author - Click to view addons
Join Date: Sep 2011
Posts: 75
https://wow.gamepedia.com/SecureActionButtonTemplate

If you want the blizzard art and stuff you can inherit from ActionButtonTemplate again, but you'll need to do most of the event handlers yourself, since blizzards handlers will most likely assume the button is using an action slot.

https://github.com/tomrus88/Blizzard...onBarFrame.xml
https://github.com/tomrus88/Blizzard...tionButton.lua

if you want to have drag/drop you'll need to simulate PlaceAction() which does a bit of the lifting for the default action buttons, you'll have to process whatever the cursor is holding, and configure the frame attributes accordingly.
when assigning the hotkey you can just bind it to click the frame, or just perform the intended command directly.
  Reply With Quote