Thread Tools Display Modes
Today, 03:18 AM   #1
Calamath
AddOn Author - Click to view addons
Join Date: Aug 2019
Posts: 43
[Open] object api for returning child index of the desired parent

There are several object APIs related to Control.

* GetChild(*luaindex* _childIndex_)
** _Returns:_ *object* _childControl_

* IsChildOf(*object* _desiredParent_)
** _Returns:_ *bool* _isChild_

However, there is no way to get the childIndex of a specific child control associated with the parent control itself.
Therefore, I would be grateful if you could add the following as an object api for Control.

* GetChildIndexOf(*object* _desiredParent_)
** _Returns:_ *luaindex* _childIndex_



I want to insert a child control from the control pool to the flex container at the next index after the specific child control.

We have SetParent and InsertChildBefore, and I would appreciate having InsertChildNext as well.

* InsertChildNext *protected-attributes* (*object* _childControl_, *object* _previousChild_)

I know using InsertChildBefore twice would do the same thing, but I think it would be wasteful to have to do the layout calculation twice.

Can you please kindly consider my proposal?
Thank you.

- Calamath

Last edited by Calamath : Today at 03:27 AM.
  Reply With Quote

ESOUI » Developer Discussions » Wish List » [Open] object api for returning child index of the desired parent


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