Package: | Ext |
Class: | BasicLayoutRegion |
Extends: | Observable |
Subclasses: | LayoutRegion |
Defined In: | BasicLayoutRegion.js |
Property | Defined By | |
---|---|---|
panels : Ext.util.MixedCollection | BasicLayoutRegion | |
A collection of panels in this region. |
Method | Defined By | |
---|---|---|
add(ContentPanel... panel ) : Ext.ContentPanel |
BasicLayoutRegion | |
Add the passed ContentPanel(s) | ||
addEvents(Object object ) : void |
Observable | |
Copies any events from the passed object onto this object if they do not already exist. The passed object must also ... | ||
addListener(String eventName , Function handler , [Object scope ], [Object options ]) : void |
Observable | |
Appends an event handler to this component | ||
fireEvent(String eventName , Object... args ) : Boolean |
Observable | |
Fires the specified event with the passed parameters (minus the event name). | ||
getActivePanel() : Ext.ContentPanel | BasicLayoutRegion | |
Get the active panel for this region. | ||
getEl() : Ext.Element | BasicLayoutRegion | |
Returns the container element for this region. | ||
getPanel(Number/String/ContentPanel panel ) : Ext.ContentPanel |
BasicLayoutRegion | |
Returns the panel specified or null if it's not in this region. | ||
getPosition() : String | BasicLayoutRegion | |
Returns this regions position (north/south/east/west/center). | ||
hasListener(String eventName ) : Boolean |
Observable | |
Checks to see if this object is currently listening for a specified event | ||
hasPanel(Number/String/ContentPanel panel ) : Boolean |
BasicLayoutRegion | |
Returns true if the panel is in this region. | ||
isVisible() : Boolean | BasicLayoutRegion | |
Returns true if this region is currently visible. | ||
on(String eventName , Function handler , [Object options ]) : void |
Observable | |
Appends an event handler to this element (shorthand for addListener) | ||
purgeListeners() : void | Observable | |
Removes all listeners for this object | ||
remove(Number/String/ContentPanel panel , Boolean preservePanel ) : Ext.ContentPanel |
BasicLayoutRegion | |
Removes the specified panel. If preservePanel is not true (either here or in the config), the panel is destroyed. | ||
removeListener(String eventName , Function handler , [Object scope ]) : void |
Observable | |
Removes a listener | ||
resizeTo(Number newSize ) : void |
BasicLayoutRegion | |
Resizes the region to the specified size. For vertical regions (west, east) this adjusts the width, for horizontal (... | ||
showPanel(Number/String/ContentPanel panelId ) : Ext.ContentPanel |
BasicLayoutRegion | |
Show the specified panel. | ||
un(String eventName , Function handler , [Object scope ]) : void |
Observable | |
Removes a listener (shorthand for removeListener) |
Event | Defined By | |
---|---|---|
beforeremove : (Ext.LayoutRegion this , Ext.ContentPanel panel , Object e ) |
BasicLayoutRegion | |
Fires before a panel is removed (or closed). To cancel the removal set "e.cancel = true" on the event argument. | ||
collapsed : (Ext.LayoutRegion this ) |
BasicLayoutRegion | |
Fires when this region is collapsed. | ||
expanded : (Ext.LayoutRegion this ) |
BasicLayoutRegion | |
Fires when this region is expanded. | ||
invalidated : (Ext.LayoutRegion this ) |
BasicLayoutRegion | |
Fires when the layout for this region is changed. | ||
panelactivated : (Ext.LayoutRegion this , Ext.ContentPanel panel ) |
BasicLayoutRegion | |
Fires when a panel is activated. | ||
paneladded : (Ext.LayoutRegion this , Ext.ContentPanel panel ) |
BasicLayoutRegion | |
Fires when a panel is added. | ||
panelremoved : (Ext.LayoutRegion this , Ext.ContentPanel panel ) |
BasicLayoutRegion | |
Fires when a panel is removed. | ||
resized : (Ext.LayoutRegion this , Number newSize ) |
BasicLayoutRegion | |
Fires when the user resizes this region. | ||
slidehide : (Ext.LayoutRegion this ) |
BasicLayoutRegion | |
Fires when this region slides out of view. | ||
slideshow : (Ext.LayoutRegion this ) |
BasicLayoutRegion | |
Fires when this region is slid into view. | ||
visibilitychange : (Ext.LayoutRegion this , Boolean visibility ) |
BasicLayoutRegion | |
Fires when this region is shown or hidden |
public Ext.util.MixedCollection panels
public function add(ContentPanel... panel
)
panel
: ContentPanel...Ext.ContentPanel
public function addEvents(Object object
)
object
: Objectvoid
public function addListener(String eventName
, Function handler
, [Object scope
], [Object options
])
eventName
: Stringhandler
: Functionscope
: Objectoptions
: Object Combining Options
Using the options argument, it is possible to combine different types of listeners:
A normalized, delayed, one-time listener that auto stops the event and passes a custom argument (forumId)
el.on('click', this.onClick, this, { single: true, delay: 100, stopEvent : true, forumId: 4 });
The method also allows for a single argument to be passed which is a config object containing properties which specify multiple handlers.
Attaching multiple handlers in 1 call
Code:
el.on({ 'click' : { fn: this.onClick scope: this, delay: 100 }, 'mouseover' : { fn: this.onMouseOver scope: this }, 'mouseout' : { fn: this.onMouseOut scope: this } });
Or a shorthand syntax:
Code:
el.on({ 'click' : this.onClick, 'mouseover' : this.onMouseOver, 'mouseout' : this.onMouseOut scope: this });
void
public function fireEvent(String eventName
, Object... args
)
eventName
: Stringargs
: Object...Boolean
public function getActivePanel()
Ext.ContentPanel
public function getEl()
Ext.Element
public function getPanel(Number/String/ContentPanel panel
)
panel
: Number/String/ContentPanelExt.ContentPanel
public function getPosition()
String
public function hasListener(String eventName
)
eventName
: StringBoolean
public function hasPanel(Number/String/ContentPanel panel
)
panel
: Number/String/ContentPanelBoolean
public function isVisible()
Boolean
public function on(String eventName
, Function handler
, [Object options
])
eventName
: Stringhandler
: Functionoptions
: Objectvoid
public function purgeListeners()
void
public function remove(Number/String/ContentPanel panel
, Boolean preservePanel
)
panel
: Number/String/ContentPanelpreservePanel
: BooleanExt.ContentPanel
public function removeListener(String eventName
, Function handler
, [Object scope
])
eventName
: Stringhandler
: Functionscope
: Objectvoid
public function resizeTo(Number newSize
)
newSize
: Numbervoid
public function showPanel(Number/String/ContentPanel panelId
)
panelId
: Number/String/ContentPanelExt.ContentPanel
public function un(String eventName
, Function handler
, [Object scope
])
eventName
: Stringhandler
: Functionscope
: Objectvoid
public event beforeremove
this
: Ext.LayoutRegionpanel
: Ext.ContentPanele
: Objectpublic event collapsed
this
: Ext.LayoutRegionpublic event expanded
this
: Ext.LayoutRegionpublic event invalidated
this
: Ext.LayoutRegionpublic event panelactivated
this
: Ext.LayoutRegionpanel
: Ext.ContentPanelpublic event paneladded
this
: Ext.LayoutRegionpanel
: Ext.ContentPanelpublic event panelremoved
this
: Ext.LayoutRegionpanel
: Ext.ContentPanelpublic event resized
this
: Ext.LayoutRegionnewSize
: Numberpublic event slidehide
this
: Ext.LayoutRegionpublic event slideshow
this
: Ext.LayoutRegionpublic event visibilitychange
this
: Ext.LayoutRegionvisibility
: Boolean