Hey
So, I've created a listbox. When I add items to the API says it returns the ID of the new item. Since I have a pointer for this listbox, this would return the ID to the pointer right? But then when I add a new item to the listbox the pointer will be the new ID. I can't create a pointer for each new item as the pointer tells the engine which listbox I am dealing with, so how would I go about this?
List Boxes
your initial understanding is wrong. read the header again:
http://irrlicht.sourceforge.net/docu/cl ... t.html#a19
the function returns a pointer to the object. The ID is set inside of the function parameters. currently there is now way that I can see to get an IGUIElement from the GUI Environment by its ID, so make sure you grab onto this pointer if you want to directly access the element in the future.
http://irrlicht.sourceforge.net/docu/cl ... t.html#a19
the function returns a pointer to the object. The ID is set inside of the function parameters. currently there is now way that I can see to get an IGUIElement from the GUI Environment by its ID, so make sure you grab onto this pointer if you want to directly access the element in the future.
a screen cap is worth 0x100000 DWORDS
That ID is the ID for the Listbox rather than each seperate item isn't it? Sorry if I'm missing something, I can be a little slow to pick up on a point. Has anyone actually got a project where they have used ID's to pick list box items so I can look at the code? I usually learn better by code than by explination.