| Defined In: | ComponentMgr.js |
| Class: | Ext.ComponentMgr |
| Extends: | Object |
为页面上全体的组件(特指 Ext.Component 的子类) 以便能够可通过 组件的id方便地访问 (see Ext.getCmp).
此对象对组件的类 classes 提供索引的功能,这个索引应是如 Ext.Component#xtype. 般的易记标识码。对于大量复合配置对象 Ext构成的页面。 xtype 避免不必要子组件实例化。只要xtype正确声明好,就可利用 配置项对象config object 表示一个子组件,这样,如遇到组件真是需要显示的时候,与之适合的类型(xtype)就会匹配对应的组件类,达到 延时实例化 lazy instantiation.
For a list of all available xtypes, see Ext.Component.
| 属性 | 定义者 | |
|---|---|---|
|
all:
为组件缓存所使用的MixedCollection。
可在这个Mi...
为组件缓存所使用的MixedCollection。
可在这个MixedCollection中加入相应的事件,监视增加或移除的情况。只读的
|
ComponentMgr | |
| 方法 | 定义者 | |
|---|---|---|
register
(
Ext.Component c
)
注册一个组件
注册一个组件
参数项:
|
ComponentMgr | |
unregister
(
Ext.Component c
)
撤消登记一个组件
撤消登记一个组件
参数项:
|
ComponentMgr | |
get
(
String id
)
:
由id返回组件
由id返回组件
参数项:
|
ComponentMgr | |
onAvailable
(
String id,
Function fn,
Object scope
)
当指定组件被加入到ComponentMgr时调用的函数。
当指定组件被加入到ComponentMgr时调用的函数。
参数项:
|
ComponentMgr | |
registerType
(
String xtype,
Constructor cls
)
输入新的Ext.Component#xtype,登记一个新组件的构...
输入新的Ext.Component#xtype,登记一个新组件的构造器。
使用该方法登记Ext.Component的子类以便当指定子组件的xtype时即可延时加载(lazy instantiation) 参阅Ext.Container#items
参数项:
|
ComponentMgr | |