| Package: | Ext | 
| Class: | SplitBar | 
| Extends: | Observable | 
| Defined In: | SplitBar.js | 
var split = new Ext.SplitBar("elementToDrag", "elementToSize",
                   Ext.SplitBar.HORIZONTAL, Ext.SplitBar.LEFT);
split.setAdapter(new Ext.SplitBar.AbsoluteLayoutAdapter("container"));
split.minSize = 100;
split.maxSize = 600;
split.animate = true;
split.on('moved', splitterMoved);        | Property | Defined By | |
|---|---|---|
| animate : Boolean | SplitBar | |
| Whether to animate the transition to the new size | ||
| maxSize : Number | SplitBar | |
| The maximum size of the resizing element. (Defaults to 2000) | ||
| minSize : Number | SplitBar | |
| The minimum size of the resizing element. (Defaults to 0) | ||
| useShim : Boolean | SplitBar | |
| Whether to create a transparent shim that overlays the page when dragging, enables dragging across iframes. | ||
| Method | Defined By | |
|---|---|---|
SplitBar( String/HTMLElement/Ext.Element dragElement, String/HTMLElement/Ext.Element resizingElement, [Number orientation], [Number placement] ) | 
        SplitBar | |
| Create a new SplitBar | ||
addEvents( Object object ) : void | 
        Observable | |
| Used to define events on this Observable | ||
addListener( String eventName, Function handler, [Object scope], [Object options] ) : void | 
        Observable | |
| Appends an event handler to this component | ||
destroy( Boolean removeEl ) : void | 
        SplitBar | |
| Destroy this splitbar. | ||
fireEvent( String eventName, Object... args ) : Boolean | 
        Observable | |
| Fires the specified event with the passed parameters (minus the event name). | ||
| getAdapter() : The | SplitBar | |
| Get the adapter this SplitBar uses | ||
| getMaximumSize() : Number | SplitBar | |
| Gets the maximum size for the resizing element | ||
| getMinimumSize() : Number | SplitBar | |
| Gets the minimum size for the resizing element | ||
hasListener( String eventName ) : Boolean | 
        Observable | |
| Checks to see if this object has any listeners for a specified event | ||
on( String eventName, Function handler, [Object scope], [Object options] ) : void | 
        Observable | |
| Appends an event handler to this element (shorthand for addListener) | ||
| purgeListeners() : void | Observable | |
| Removes all listeners for this object | ||
removeListener( String eventName, Function handler, [Object scope] ) : void | 
        Observable | |
| Removes a listener | ||
setAdapter( Object adapter ) : void | 
        SplitBar | |
| Set the adapter this SplitBar uses | ||
setCurrentSize( Number size ) : void | 
        SplitBar | |
| Sets the initialize size for the resizing element | ||
setMaximumSize( Number maxSize ) : void | 
        SplitBar | |
| Sets the maximum size for the resizing element | ||
setMinimumSize( Number minSize ) : void | 
        SplitBar | |
| Sets the minimum size for the resizing element | ||
un( String eventName, Function handler, [Object scope] ) : void | 
        Observable | |
| Removes a listener (shorthand for removeListener) | ||
| Event | Defined By | |
|---|---|---|
beforeresize : ( Ext.SplitBar this ) | 
        SplitBar | |
| Fires before the splitter is dragged | ||
moved : ( Ext.SplitBar this, Number newSize ) | 
        SplitBar | |
| Fires when the splitter is moved | ||
resize : ( Ext.SplitBar this, Number newSize ) | 
        SplitBar | |
| Fires when the splitter is moved (alias for {@link #event-moved}) | ||
public Boolean animate
                public Number maxSize
                public Number minSize
                public Boolean useShim
                public function SplitBar( String/HTMLElement/Ext.Element dragElement, String/HTMLElement/Ext.Element resizingElement, [Number orientation], [Number placement] )
                dragElement : String/HTMLElement/Ext.ElementresizingElement : String/HTMLElement/Ext.Elementorientation : Numberplacement : Numberpublic function addEvents( Object object )
                object : Objectvoidpublic 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,
    		forumId: 4
		});
Attaching multiple handlers in 1 call
The method also allows for a single argument to be passed which is a config object containing properties
which specify multiple handlers.
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 which passes the same scope object to all handlers:
el.on({
			'click': this.onClick,
    		'mouseover': this.onMouseOver,
    		'mouseout': this.onMouseOut,
    		scope: this
		});voidpublic function destroy( Boolean removeEl )
                removeEl : Booleanvoidpublic function fireEvent( String eventName, Object... args )
                eventName : Stringargs : Object...Booleanpublic function getAdapter()
                Thepublic function getMaximumSize()
                Numberpublic function getMinimumSize()
                Numberpublic function hasListener( String eventName )
                eventName : StringBooleanpublic function on( String eventName, Function handler, [Object scope], [Object options] )
                eventName : Stringhandler : Functionscope : Objectoptions : Objectvoidpublic function purgeListeners()
                voidpublic function removeListener( String eventName, Function handler, [Object scope] )
                eventName : Stringhandler : Functionscope : Objectvoidpublic function setAdapter( Object adapter )
                adapter : Objectvoidpublic function setCurrentSize( Number size )
                size : Numbervoidpublic function setMaximumSize( Number maxSize )
                maxSize : Numbervoidpublic function setMinimumSize( Number minSize )
                minSize : Numbervoidpublic function un( String eventName, Function handler, [Object scope] )
                eventName : Stringhandler : Functionscope : Objectvoidpublic event beforeresize
                this : Ext.SplitBarpublic event moved
                this : Ext.SplitBarnewSize : Numberpublic event resize
                this : Ext.SplitBarnewSize : Number