PDA

View Full Version : baseAction in Component class



actonwang
28 Oct 2010, 8:20 AM
hi,

in Component.js, there is a field called baseAction, the related code is as :

if(this.baseAction) {
this.baseAction.addComponent(this);
}

could anyone help to refer to any source to explain what is the purpose of this baseAction and how we would use it?

thx a lot!
Acton

Condor
28 Oct 2010, 8:34 AM
Have a look at the Ext.Action class and the examples/menu/actions.html example.

actonwang
28 Oct 2010, 9:18 AM
thanks. will look:

quick thing here:
1.Ext.Action doesn't have addComponent function so I am not sure how this works:

>>this.baseAction.addComponent(this);

2. looks the action only applies certain component such as Menu, Button so why it is in Component class then?

thx a lot
Acton

actonwang
28 Oct 2010, 10:08 AM
ignore above question. I know what is going on now..
the so called private functions are being called...