Class sap.tnt.SideNavigationModule: sap/tnt/SideNavigation

extends Control

The SideNavigation control is a container, which consists of flexible and fixed parts on top of each other. The flexible part adapts its size to the fixed one. The flexible part has a scrollbar when the content is larger than the available space. Whenever the height of the whole control is less than 256 pixels, the scrollbar becomes joint for the two parts.

Note: In order for the SideNavigation to stretch properly, its parent layout control should only be the sap.tnt.ToolPage.


Since: 1.34.
Constructor Summary
new sap.tnt.SideNavigation(sId?, mSettings?)Constructor for a new SideNavigation.
Event Summary
itemSelect(oControlEvent)Fired when an item is selected.
Events borrowed from class sap.ui.core.Control
Method Summary
sap.tnt.SideNavigation.extend(sClassName, oClassInfo?, FNMetaImpl?)Creates a new subclass of class sap.tnt.SideNavigation with name sClassName and enriches it with the information contained in oClassInfo.
sap.tnt.SideNavigation.getMetadata()Returns a metadata object for class sap.tnt.SideNavigation.
attachItemSelect(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the itemSelect event of this sap.tnt.SideNavigation.
bindItem(oBindingInfo)Binds aggregation item to model data.
destroyFixedItem()Destroys the fixedItem in the aggregation fixedItem.
destroyFooter()Destroys the footer in the aggregation footer.
destroyItem()Destroys the item in the aggregation item.
detachItemSelect(fnFunction, oListener)Detaches event handler fnFunction from the itemSelect event of this sap.tnt.SideNavigation.
fireItemSelect(mParameters?)Fires event itemSelect to attached listeners.
getExpanded()Gets current value of property expanded.
getFixedItem()Gets content of aggregation fixedItem.
getFooter()Gets content of aggregation footer.
getItem()Gets content of aggregation item.
setFixedItem(oFixedItem)Sets the aggregated fixedItem.
setFooter(oFooter)Sets the aggregated footer.
setItem(oItem)Sets the aggregated item.
unbindItem()Unbinds aggregation item from model data.
Constructor Detail
new sap.tnt.SideNavigation(sId?, mSettings?)

Constructor for a new SideNavigation.

Accepts an object literal mSettings that defines initial property values, aggregated and associated objects as well as event handlers. See sap.ui.base.ManagedObject for a general description of the syntax of the settings object.

The supported settings are:

  • Properties

  • Aggregations

    • item : sap.tnt.NavigationList (default)
    • fixedItem : sap.tnt.NavigationList
    • footer : sap.tnt.NavigationList

  • Events

    • itemSelect : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]

In addition, all settings applicable to the base type sap.ui.core.Control can be used as well.

Parameters:
stringsId?ID for the new control, generated automatically if no ID is given
objectmSettings?Initial settings for the new control
Event Detail
itemSelect(oControlEvent)
Fired when an item is selected.
Parameters:
sap.ui.base.EventoControlEvent
sap.ui.base.EventProvideroControlEvent.getSource
objectoControlEvent.getParameters
sap.ui.core.ItemoControlEvent.getParameters.itemThe selected item.
Method Detail
sap.tnt.SideNavigation.extend(sClassName, oClassInfo?, FNMetaImpl?): function

Creates a new subclass of class sap.tnt.SideNavigation with name sClassName and enriches it with the information contained in oClassInfo.

oClassInfo might contain the same kind of information as described in sap.ui.core.Control.extend.

Parameters:
stringsClassNameName of the class being created
objectoClassInfo?Object literal with information about the class
functionFNMetaImpl?Constructor function for the metadata object; if not given, it defaults to sap.ui.core.ElementMetadata
Returns:
functionCreated class / constructor function
sap.tnt.SideNavigation.getMetadata(): sap.ui.base.Metadata
Returns a metadata object for class sap.tnt.SideNavigation.
Returns:
sap.ui.base.MetadataMetadata object describing this class
attachItemSelect(oData?, fnFunction, oListener?): sap.tnt.SideNavigation

Attaches event handler fnFunction to the itemSelect event of this sap.tnt.SideNavigation.

When called, the context of the event handler (its this) will be bound to oListener if specified, otherwise it will be bound to this sap.tnt.SideNavigation itself.

Fired when an item is selected.

Parameters:
objectoData?An application-specific payload object that will be passed to the event handler along with the event object when firing the event
functionfnFunctionThe function to be called when the event occurs
objectoListener?Context object to call the event handler with. Defaults to this sap.tnt.SideNavigation itself
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining
bindItem(oBindingInfo): sap.tnt.SideNavigation

Binds aggregation item to model data.

See ManagedObject.bindAggregation for a detailed description of the possible properties of oBindingInfo.

Parameters:
objectoBindingInfoThe binding information
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining
destroyFixedItem(): sap.tnt.SideNavigation
Destroys the fixedItem in the aggregation fixedItem.
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining
destroyFooter(): sap.tnt.SideNavigation
Destroys the footer in the aggregation footer.
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining
destroyItem(): sap.tnt.SideNavigation
Destroys the item in the aggregation item.
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining
detachItemSelect(fnFunction, oListener): sap.tnt.SideNavigation

Detaches event handler fnFunction from the itemSelect event of this sap.tnt.SideNavigation.

The passed function and listener object must match the ones used for event registration.

Parameters:
functionfnFunctionThe function to be called, when the event occurs
objectoListenerContext object on which the given function had to be called
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining
fireItemSelect(mParameters?): sap.tnt.SideNavigation
Fires event itemSelect to attached listeners.
Parameters:
objectmParameters?Parameters to pass along with the event
sap.ui.core.ItemmParameters.item?The selected item.
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining
getExpanded(): boolean

Gets current value of property expanded.

Specifies if the control is expanded.

Default value is true.

Returns:
booleanValue of property expanded
getFixedItem(): sap.tnt.NavigationList

Gets content of aggregation fixedItem.

Defines the content inside the fixed part.

Returns:
sap.tnt.NavigationList

Gets content of aggregation footer.

Defines the content inside the footer.

Returns:
sap.tnt.NavigationList

Gets content of aggregation item.

Defines the content inside the flexible part.

Returns:
sap.tnt.NavigationList
setFixedItem(oFixedItem): sap.tnt.SideNavigation
Sets the aggregated fixedItem.
Parameters:
sap.tnt.NavigationListoFixedItemThe fixedItem to set
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining
setFooter(oFooter): sap.tnt.SideNavigation
Sets the aggregated footer.
Parameters:
sap.tnt.NavigationListoFooterThe footer to set
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining
setItem(oItem): sap.tnt.SideNavigation
Sets the aggregated item.
Parameters:
sap.tnt.NavigationListoItemThe item to set
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining
unbindItem(): sap.tnt.SideNavigation
Unbinds aggregation item from model data.
Returns:
sap.tnt.SideNavigationReference to this in order to allow method chaining