PDA

View Full Version : How to get all items of panel?



pirusira
25 May 2010, 12:05 AM
Hello All,

The following is code of CenterArea.js


CenterArea = function(viewport){
this.viewport = viewport;
CenterArea.superclass.constructor.call(this,{
region: 'center',
title: false,
layout: 'border',
border: false,
items: [nestedCenter, nestedSouth]
})
};
Ext.extend(CenterArea, Ext.Panel,{ });

I want to get all items of the panel nestedCenter.
If the variable of all items is 'allItems' then I would hide it like this:


allItems.hide();

But I don't know how to get the object of the items.

Thanks in advance.
Stan

pirusira
25 May 2010, 12:25 AM
I just found out that all items are organized as an array.
So I can get one of items like this.


nestedCenter.items.items[1]

And I found out that I can get the number of those items like this.


nestedCenter.items.length

So I can solve it now. :)