PDA

View Full Version : get list of items in a toolbar



spinnerdog
7 Jun 2012, 7:23 AM
How do you get a list if items in a tool bar? Is there a function for this or just iterate through toobar.items array?

Tim Toady
7 Jun 2012, 7:34 AM
It is a subclass of container so you can access it just like any container/panel/etc. You can iterate over items or componentQuery them or any other way you would normally use.

spinnerdog
7 Jun 2012, 7:54 AM
"
You can iterate over items or componentQuery them or any other way you would normally use."

was looking for something similar to grid.getDockedItems that returns an array.

do you mean

for( var i=0;i < tbar.items.length; ++i ){
modify( tbar.items[i] );
}