class sap.m.OverflowToolbarButton

Visiblity: public
UX Guidelines:
Implements: sap.f.IShellBarsap.m.IOverflowToolbarContent
Available since: N/A
Extends: sap.m.Button
Module: sap/m/OverflowToolbarButton
Application Component: CA-UI5-CTR

Represents an sap.m.Button that shows its text only when in the overflow area of an sap.m.OverflowToolbar.

Note: This control is intended to be used exclusively in the context of the OverflowToolbar, whenever it is required to have buttons that show only an icon in the toolbar, but icon and text in the overflow menu.


Constructor

Constructor for a new OverflowToolbarButton.

new sap.m.OverflowToolbarButton(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

Borrowed Properties

Name Type Default Value Description
activeIcon sap.ui.core.URI

The source property of an alternative icon for the active (depressed) state of the button. Both active and default icon properties should be defined and have the same type: image or icon font. If the icon property is not set or has a different type, the active icon is not displayed.

Visibility: public
ariaHasPopup sap.ui.core.aria.HasPopup None

Specifies the value of the aria-haspopup attribute

If the value is None, the attribute will not be rendered. Otherwise it will be rendered with the selected value.

NOTE: Use this property only when a button is related to a popover/popup. The value needs to be equal to the main/root role of the popup - e.g. dialog, menu or list (examples: if you have dialog -> dialog, if you have menu -> menu; if you have list -> list; if you have dialog containing a list -> dialog). Do not use it, if you open a standard sap.m.Dialog, MessageBox or other type of dialogs displayed as on overlay over the application.

Since: 1.84.0.

Visibility: public
enabled boolean true

Determines whether the Button is enabled (default is set to true). A disabled Button has different colors depending on the ButtonType.

Visibility: public
icon sap.ui.core.URI empty string

Defines the icon to be displayed as graphical element within the Button. It can be an image or an icon from the icon font.

Visibility: public
iconDensityAware boolean true

By default, this is set to true but then one or more requests are sent trying to get the density perfect version of image if this version of image doesn't exist on the server.

If only one version of image is provided, set this value to false to avoid the attempt of fetching density perfect image.

Visibility: public
iconFirst boolean true

Determines whether the icon is displayed before the text.

Visibility: public
text string empty string

Determines the text of the Button.

Visibility: public
textDirection sap.ui.core.TextDirection Inherit

Specifies the element's text directionality with enumerated options. By default, the control inherits text direction from the DOM.

Since: 1.28.0.

Visibility: public
type sap.m.ButtonType Default

Defines the Button type.

Visibility: public
width sap.ui.core.CSSSize

Defines the Button width.

Visibility: public

Methods Overview

Method Description
sap.m.OverflowToolbarButton.extend

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

oClassInfo might contain the same kind of information as described in sap.m.Button.extend.

sap.m.OverflowToolbarButton.getMetadata

Returns a metadata object for class sap.m.OverflowToolbarButton.

sap.m.OverflowToolbarButton.extend

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

oClassInfo might contain the same kind of information as described in sap.m.Button.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

sap.m.OverflowToolbarButton.getMetadata

Returns a metadata object for class sap.m.OverflowToolbarButton.