Thread Tools Display Modes
04-21-20, 11:11 AM   #1
GreenCoyote
A Murloc Raider
 
GreenCoyote's Avatar
Join Date: Apr 2020
Posts: 5
Red face How to get user select of an item in a bag?

Hello all!
Then auction/trade/send mail/vendor/etc window(frame) is opened, if user pressing right mouse button on an item in his inventory – action happens, like sell item to vendor, or post item to auction, or trade it to stranger etc.
How to do this in my addon? How to get bag+slot user selected item?
I tried to google it in different ways, but failed. Can someone help me with this?
  Reply With Quote
04-21-20, 03:42 PM   #2
elcius
A Cliff Giant
AddOn Author - Click to view addons
Join Date: Sep 2011
Posts: 75
the code that handles item clicking can be found here, but that's probably not what you need, since you need to intercept the clicks on the button frames directly to avoid breaking stuff.

the easiest way to do it is to listen for a modified click, pre-hooking HandleModifiedItemClick shouldn't cause taint.
if you want to listen for simple raw clicks then it gets quite complicated, probably involving invisible secure overlay frames for every item button.
  Reply With Quote

WoWInterface » Developer Discussions » Lua/XML Help » How to get user select of an item in a bag?

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off