According to the docs, the default items of the titlebar is xbutton. So I have a titlebar and three buttons added to it. So the titlebar has three items. One button aligned to left and two to the right.
However, when in my controller I do a this.getTitleBar().getItems() it doesn't return buttons. It returns containers and components. One of the component is the title of the titlebar, which I get.
In order to get to the buttons, they are buried as innerItems of various containers. This doesn't make any sense to me.
If the documentation says that getItems() will return the items of the titlebar, and if I add three buttons, why am I not getting three buttons back?
How can I get an array of the items (which are buttons) of a titlebar? I need to iterate through all the buttons in the titlebar and this seemingly simple task is turning out to be a nightmare.