An item to be used in a TabContainer.
Constructor for a new TabContainerItem
.
Accepts an object literal mSettings
that defines initial property values, aggregated and associated objects as well as event handlers. See sap.ui.base.ManagedObject#constructor for a general description of the syntax of the settings object.
new sap.m.TabContainerItem(sId?, mSettings?)
Param | Type | Default Value | Description |
---|---|---|---|
sId? | string | ID for the new control, generated automatically if no ID is given |
|
mSettings? | object | Initial settings for the new control |
Name | Type | Default Value | Description |
---|---|---|---|
additionalText | string | empty string | Determines additional text to be displayed for the item. Visibility: public |
icon | sap.ui.core.URI | Defines the icon to be displayed as graphical element within the |
|
iconTooltip | string | Determines the tooltip text of the |
|
key | string | Determines the name of the item. Can be used as input for subsequent actions. Visibility: public |
|
modified | boolean | false | Shows if a control is edited (default is false). Items that are marked as modified have a * symbol to indicate that they haven't been saved. Visibility: public |
name | string | empty string | Determines the text to be displayed for the item. Visibility: public |
Default Aggregation:
Name | Cardinality | Type | Description |
---|---|---|---|
_image | 0..1 | sap.ui.core.Control |
Icon / Image for the |
content | 0..n | sap.ui.core.Control |
The content displayed for this item. |
Event | Description |
---|---|
itemPropertyChanged |
Sends information that some of the properties have changed. |
Sends information that some of the properties have changed.
Param | Type | Description |
---|---|---|
oControlEvent | sap.ui.base.Event | |
getSource | sap.ui.base.EventProvider | |
getParameters | object | |
itemChanged | sap.m.TabContainerItem |
The item changed. |
propertyKey | string |
The key of the property. |
propertyValue | any |
The value of the property. |
Method | Description |
---|---|
addContent |
Adds some content to the aggregation content. |
attachItemPropertyChanged |
Attaches event handler When called, the context of the event handler (its Sends information that some of the properties have changed. |
destroyContent |
Destroys all the content in the aggregation content. |
detachItemPropertyChanged |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
sap.m.TabContainerItem.extend |
Creates a new subclass of class sap.m.TabContainerItem with name
|
fireItemPropertyChanged |
Fires event itemPropertyChanged to attached listeners. |
getAdditionalText |
Gets current value of property additionalText. Determines additional text to be displayed for the item. Default value is |
getContent |
Gets content of aggregation content. The content displayed for this item. |
getIcon |
Gets current value of property icon. Defines the icon to be displayed as graphical element within the |
getIconTooltip |
Gets current value of property iconTooltip. Determines the tooltip text of the |
getKey |
Gets current value of property key. Determines the name of the item. Can be used as input for subsequent actions. |
sap.m.TabContainerItem.getMetadata |
Returns a metadata object for class sap.m.TabContainerItem. |
getModified |
Gets current value of property modified. Shows if a control is edited (default is false). Items that are marked as modified have a * symbol to indicate that they haven't been saved. Default value is |
getName |
Gets current value of property name. Determines the text to be displayed for the item. Default value is |
indexOfContent |
Checks for the provided |
insertContent |
Inserts a content into the aggregation content. |
removeAllContent |
Removes all the controls from the aggregation content. Additionally, it unregisters them from the hosting UIArea. |
removeContent |
Removes a content from the aggregation content. |
setAdditionalText |
Sets a new value for property additionalText. Determines additional text to be displayed for the item. When called with a value of Default value is |
setIcon |
Property setter for the icon |
setIconTooltip |
Sets a new value for property iconTooltip. Determines the tooltip text of the When called with a value of |
setKey |
Sets a new value for property key. Determines the name of the item. Can be used as input for subsequent actions. When called with a value of |
setModified |
Sets a new value for property modified. Shows if a control is edited (default is false). Items that are marked as modified have a * symbol to indicate that they haven't been saved. When called with a value of Default value is |
setName |
Sets a new value for property name. Determines the text to be displayed for the item. When called with a value of Default value is |
setProperty |
Overwrites the method in order to suppress invalidation for some properties. |
Adds some content to the aggregation content.
Param | Type | DefaultValue | Description |
---|---|---|---|
oContent | sap.ui.core.Control |
The content to add; if empty, nothing is inserted |
Attaches event handler fnFunction
to the itemPropertyChanged event of this sap.m.TabContainerItem
.
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.m.TabContainerItem
itself.
Sends information that some of the properties have changed.
Param | Type | DefaultValue | Description |
---|---|---|---|
oData | object |
An application-specific payload object that will be passed to the event handler along with the event object when firing the event |
|
fnFunction | function(sap.ui.base.Event) : void |
The function to be called when the event occurs |
|
oListener | object |
Context object to call the event handler with. Defaults to this |
Detaches event handler fnFunction
from the itemPropertyChanged event of this sap.m.TabContainerItem
.
The passed function and listener object must match the ones used for event registration.
Param | Type | DefaultValue | Description |
---|---|---|---|
fnFunction | function(sap.ui.base.Event) : void |
The function to be called, when the event occurs |
|
oListener | object |
Context object on which the given function had to be called |
Creates a new subclass of class sap.m.TabContainerItem 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.Element.extend.
Param | Type | DefaultValue | Description |
---|---|---|---|
sClassName | string |
Name of the class being created |
|
oClassInfo | object |
Object literal with information about the class |
|
FNMetaImpl | function |
Constructor function for the metadata object; if not given, it defaults to the metadata implementation used by this class |
Fires event itemPropertyChanged to attached listeners.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
|
itemChanged | sap.m.TabContainerItem |
The item changed. |
|
propertyKey | string |
The key of the property. |
|
propertyValue | any |
The value of the property. |
Gets current value of property additionalText.
Determines additional text to be displayed for the item.
Default value is empty string
.
Gets current value of property icon.
Defines the icon to be displayed as graphical element within the TabContainerItem
. It can be an image or an icon from the icon font.
Gets current value of property iconTooltip.
Determines the tooltip text of the TabContainerItem
's icon.
Gets current value of property key.
Determines the name of the item. Can be used as input for subsequent actions.
Gets current value of property modified.
Shows if a control is edited (default is false). Items that are marked as modified have a * symbol to indicate that they haven't been saved.
Default value is false
.
Gets current value of property name.
Determines the text to be displayed for the item.
Default value is empty string
.
Checks for the provided sap.ui.core.Control
in the aggregation content. and returns its index if found or -1 otherwise.
Param | Type | DefaultValue | Description |
---|---|---|---|
oContent | sap.ui.core.Control |
The content whose index is looked for |
Inserts a content into the aggregation content.
Param | Type | DefaultValue | Description |
---|---|---|---|
oContent | sap.ui.core.Control |
The content to insert; if empty, nothing is inserted |
|
iIndex | int |
The |
Removes all the controls from the aggregation content.
Additionally, it unregisters them from the hosting UIArea.
Removes a content from the aggregation content.
Param | Type | DefaultValue | Description |
---|---|---|---|
vContent | int string sap.ui.core.Control |
The content to remove or its index or id |
Sets a new value for property additionalText.
Determines additional text to be displayed for the item.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is empty string
.
Param | Type | DefaultValue | Description |
---|---|---|---|
sAdditionalText | string | "" |
New value for property |
Property setter for the icon
Param | Type | DefaultValue | Description |
---|---|---|---|
sIcon | sap.ui.core.URI |
new value of the Icon property |
Sets a new value for property iconTooltip.
Determines the tooltip text of the TabContainerItem
's icon.
When called with a value of null
or undefined
, the default value of the property will be restored.
Param | Type | DefaultValue | Description |
---|---|---|---|
sIconTooltip | string |
New value for property |
Sets a new value for property key.
Determines the name of the item. Can be used as input for subsequent actions.
When called with a value of null
or undefined
, the default value of the property will be restored.
Param | Type | DefaultValue | Description |
---|---|---|---|
sKey | string |
New value for property |
Sets a new value for property modified.
Shows if a control is edited (default is false). Items that are marked as modified have a * symbol to indicate that they haven't been saved.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is false
.
Param | Type | DefaultValue | Description |
---|---|---|---|
bModified | boolean | false |
New value for property |
Sets a new value for property name.
Determines the text to be displayed for the item.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is empty string
.
Param | Type | DefaultValue | Description |
---|---|---|---|
sName | string | "" |
New value for property |