Class sap.ui.ux3.OverlayModule: sap/ui/ux3/Overlay

extends Control
implements PopupInterface
known direct subclasses: OverlayContainer, OverlayDialog, ThingInspector

Overlay Control
Deprecated API:
Since version 1.38.
Constructor Summary
new sap.ui.ux3.Overlay(sId?, mSettings?)Constructor for a new Overlay.
Event Summary
close(oControlEvent)Event is fired when the Overlay starts closing.
closed(oControlEvent)Event is fired when the Overlay is closed.
open(oControlEvent)Event is fired when the Overlay is opened.
openNew(oControlEvent)Event is fired when the 'Open' button of the Overlay is clicked.
Events borrowed from class sap.ui.core.Control
Method Summary
sap.ui.ux3.Overlay.extend(sClassName, oClassInfo?, FNMetaImpl?)Creates a new subclass of class sap.ui.ux3.Overlay with name sClassName and enriches it with the information contained in oClassInfo.
sap.ui.ux3.Overlay.getMetadata()Returns a metadata object for class sap.ui.ux3.Overlay.
attachClose(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the close event of this sap.ui.ux3.Overlay.
attachClosed(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the closed event of this sap.ui.ux3.Overlay.
attachOpen(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the open event of this sap.ui.ux3.Overlay.
attachOpenNew(oData?, fnFunction, oListener?)Attaches event handler fnFunction to the openNew event of this sap.ui.ux3.Overlay.
close()Closes the Overlay.
detachClose(fnFunction, oListener)Detaches event handler fnFunction from the close event of this sap.ui.ux3.Overlay.
detachClosed(fnFunction, oListener)Detaches event handler fnFunction from the closed event of this sap.ui.ux3.Overlay.
detachOpen(fnFunction, oListener)Detaches event handler fnFunction from the open event of this sap.ui.ux3.Overlay.
detachOpenNew(fnFunction, oListener)Detaches event handler fnFunction from the openNew event of this sap.ui.ux3.Overlay.
fireClose(mParameters?)Fires event close to attached listeners.
fireClosed(mParameters?)Fires event closed to attached listeners.
fireOpen(mParameters?)Fires event open to attached listeners.
fireOpenNew(mParameters?)Fires event openNew to attached listeners.
getCloseButtonVisible()Gets current value of property closeButtonVisible.
getOpenButtonVisible()Gets current value of property openButtonVisible.
isOpen()Checks whether Overlay is open.
open(initialFocusId)Opens the Overlay.
setCloseButtonVisible(bCloseButtonVisible)Sets a new value for property closeButtonVisible.
setOpenButtonVisible(bOpenButtonVisible)Sets a new value for property openButtonVisible.
Constructor Detail
new sap.ui.ux3.Overlay(sId?, mSettings?)

Constructor for a new Overlay.

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

  • Events

    • close : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • closed : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • openNew : fnListenerFunction or [fnListenerFunction, oListenerObject] or [oData, fnListenerFunction, oListenerObject]
    • open : 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
close(oControlEvent)
Event is fired when the Overlay starts closing.
Parameters:
sap.ui.base.EventoControlEvent
sap.ui.base.EventProvideroControlEvent.getSource
objectoControlEvent.getParameters
stringoControlEvent.getParameters.idThe ID of the Overlay instance.
closed(oControlEvent)
Event is fired when the Overlay is closed.
Parameters:
sap.ui.base.EventoControlEvent
sap.ui.base.EventProvideroControlEvent.getSource
objectoControlEvent.getParameters
stringoControlEvent.getParameters.idThe ID of the Overlay instance.
open(oControlEvent)
Event is fired when the Overlay is opened.
Parameters:
sap.ui.base.EventoControlEvent
sap.ui.base.EventProvideroControlEvent.getSource
objectoControlEvent.getParameters
stringoControlEvent.getParameters.idThe ID of the Overlay instance
openNew(oControlEvent)
Event is fired when the 'Open' button of the Overlay is clicked.
Parameters:
sap.ui.base.EventoControlEvent
sap.ui.base.EventProvideroControlEvent.getSource
objectoControlEvent.getParameters
stringoControlEvent.getParameters.idThe ID of the Overlay instance.
Method Detail
sap.ui.ux3.Overlay.extend(sClassName, oClassInfo?, FNMetaImpl?): function

Creates a new subclass of class sap.ui.ux3.Overlay 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.ui.ux3.Overlay.getMetadata(): sap.ui.base.Metadata
Returns a metadata object for class sap.ui.ux3.Overlay.
Returns:
sap.ui.base.MetadataMetadata object describing this class
attachClose(oData?, fnFunction, oListener?): sap.ui.ux3.Overlay

Attaches event handler fnFunction to the close event of this sap.ui.ux3.Overlay.

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.ui.ux3.Overlay itself.

Event is fired when the Overlay starts closing.

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.ui.ux3.Overlay itself
Returns:
sap.ui.ux3.OverlayReference to this in order to allow method chaining
attachClosed(oData?, fnFunction, oListener?): sap.ui.ux3.Overlay

Attaches event handler fnFunction to the closed event of this sap.ui.ux3.Overlay.

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.ui.ux3.Overlay itself.

Event is fired when the Overlay is closed.

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.ui.ux3.Overlay itself
Returns:
sap.ui.ux3.OverlayReference to this in order to allow method chaining
attachOpen(oData?, fnFunction, oListener?): sap.ui.ux3.Overlay

Attaches event handler fnFunction to the open event of this sap.ui.ux3.Overlay.

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.ui.ux3.Overlay itself.

Event is fired when the Overlay is opened.

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.ui.ux3.Overlay itself
Returns:
sap.ui.ux3.OverlayReference to this in order to allow method chaining
attachOpenNew(oData?, fnFunction, oListener?): sap.ui.ux3.Overlay

Attaches event handler fnFunction to the openNew event of this sap.ui.ux3.Overlay.

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.ui.ux3.Overlay itself.

Event is fired when the 'Open' button of the Overlay is clicked.

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.ui.ux3.Overlay itself
Returns:
sap.ui.ux3.OverlayReference to this in order to allow method chaining
close()
Closes the Overlay.
detachClose(fnFunction, oListener): sap.ui.ux3.Overlay

Detaches event handler fnFunction from the close event of this sap.ui.ux3.Overlay.

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.ui.ux3.OverlayReference to this in order to allow method chaining
detachClosed(fnFunction, oListener): sap.ui.ux3.Overlay

Detaches event handler fnFunction from the closed event of this sap.ui.ux3.Overlay.

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.ui.ux3.OverlayReference to this in order to allow method chaining
detachOpen(fnFunction, oListener): sap.ui.ux3.Overlay

Detaches event handler fnFunction from the open event of this sap.ui.ux3.Overlay.

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.ui.ux3.OverlayReference to this in order to allow method chaining
detachOpenNew(fnFunction, oListener): sap.ui.ux3.Overlay

Detaches event handler fnFunction from the openNew event of this sap.ui.ux3.Overlay.

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.ui.ux3.OverlayReference to this in order to allow method chaining
fireClose(mParameters?): boolean

Fires event close to attached listeners.

Listeners may prevent the default action of this event by using the preventDefault-method on the event object.

Parameters:
objectmParameters?Parameters to pass along with the event
stringmParameters.id?The ID of the Overlay instance.
Returns:
booleanWhether or not to prevent the default action
fireClosed(mParameters?): boolean

Fires event closed to attached listeners.

Listeners may prevent the default action of this event by using the preventDefault-method on the event object.

Parameters:
objectmParameters?Parameters to pass along with the event
stringmParameters.id?The ID of the Overlay instance.
Returns:
booleanWhether or not to prevent the default action
fireOpen(mParameters?): sap.ui.ux3.Overlay
Fires event open to attached listeners.
Parameters:
objectmParameters?Parameters to pass along with the event
stringmParameters.id?The ID of the Overlay instance
Returns:
sap.ui.ux3.OverlayReference to this in order to allow method chaining
fireOpenNew(mParameters?): sap.ui.ux3.Overlay
Fires event openNew to attached listeners.
Parameters:
objectmParameters?Parameters to pass along with the event
stringmParameters.id?The ID of the Overlay instance.
Returns:
sap.ui.ux3.OverlayReference to this in order to allow method chaining
getCloseButtonVisible(): boolean

Gets current value of property closeButtonVisible.

Defines whether the 'Close' button shall be visible.

Default value is true.

Returns:
booleanValue of property closeButtonVisible
getOpenButtonVisible(): boolean

Gets current value of property openButtonVisible.

Defines whether the 'Open' button shall be visible.

Default value is true.

Returns:
booleanValue of property openButtonVisible
isOpen(): boolean
Checks whether Overlay is open.
Returns:
boolean
open(initialFocusId)
Opens the Overlay.
Parameters:
stringinitialFocusIdID of the control that gets focused when the overlay is openend
setCloseButtonVisible(bCloseButtonVisible): sap.ui.ux3.Overlay

Sets a new value for property closeButtonVisible.

Defines whether the 'Close' button shall be visible.

When called with a value of null or undefined, the default value of the property will be restored.

Default value is true.

Parameters:
booleanbCloseButtonVisibleNew value for property closeButtonVisible
Returns:
sap.ui.ux3.OverlayReference to this in order to allow method chaining
setOpenButtonVisible(bOpenButtonVisible): sap.ui.ux3.Overlay

Sets a new value for property openButtonVisible.

Defines whether the 'Open' button shall be visible.

When called with a value of null or undefined, the default value of the property will be restored.

Default value is true.

Parameters:
booleanbOpenButtonVisibleNew value for property openButtonVisible
Returns:
sap.ui.ux3.OverlayReference to this in order to allow method chaining