WoWInterface

WoWInterface (https://www.wowinterface.com/forums/index.php)
-   General Authoring Discussion (https://www.wowinterface.com/forums/forumdisplay.php?f=20)
-   -   GossipFrame - GreetingText - EnumerateAtcive() (https://www.wowinterface.com/forums/showthread.php?t=59536)

Platine 03-20-23 02:54 AM

GossipFrame - GreetingText - EnumerateAtcive()
 
I have an object GreetingText in GossipFrame as Enumerate element.
In the photo it is an GossipFrame.GreetingPanel.ScrollBox.ScrollTarget.9bf0def0.GreetingText object.
How do I use the command below to access them?

Quote:

for greetingText in GossipFrame.GreetingPanel.ScrollBox.ScrollTarget.XXXFramePool:EnumerateActive() do


Or what is another method to get the name of this object?

SDPhantom 03-20-23 12:34 PM

This is what I have in one of my personal addons.
Code:

for button in QuestFrameGreetingPanel.titleButtonPool:EnumerateActive() do

Platine 03-25-23 04:40 AM

Thank you SDPhantom, but this is a call for QuestFrame.
In GossipFrame this unfortunately doesn't work.
So there must be some other name for these objects.

SDPhantom 03-25-23 07:28 PM

There are a couple different systems that are used for the greeting panel and which one pops up depends on the NPC's implementation. GossipFrame specifically uses the new dataprovider-sourced scrollbox, which is more abstract and a pain to follow than previously.

This might do the trick though.
Code:

for _,frame in GossipFrame.GreetingPanel.ScrollBox:EnumerateFrames() do
Note: Despite employing frame pools, it doesn't implement FramePoolMixin.
Not all ScrollBoxes will have :EnumerateFrames() either. It's an exclusive method of ScrollBoxListMixin. However the equivalent could be achieved with the other types by using ipairs(ScrollBox:GetFrames()).

Platine 03-27-23 06:14 AM

Thanks, this gives the GreetingText enumeric object well in GossipFrame.


All times are GMT -6. The time now is 06:46 PM.

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