CalloutBase is a building block for Callout. Do not use it directly. Use the Callout control instead
Constructor for a new CalloutBase.
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.ui.commons.CalloutBase(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 |
Event | Description |
---|---|
beforeOpen |
Event is fired before a Callout is displayed. Call the preventDefault method of the event object to postpone opening. Application may use this event to start asynchronous Ajax call to load the Callout content Listeners may prevent the default action of this event by calling the |
close |
Event is fired when the Callout window is closed. |
open |
The event is fired when the popup is opened. |
opened |
Is fired when the Callout has been opened |
Event is fired before a Callout is displayed. Call the preventDefault method of the event object to postpone opening. Application may use this event to start asynchronous Ajax call to load the Callout content
Listeners may prevent the default action of this event by calling the preventDefault
method on the event object.
Param | Type | Description |
---|---|---|
oControlEvent | sap.ui.base.Event | |
getSource | sap.ui.base.EventProvider | |
getParameters | object | |
parent | sap.ui.core.Control |
Parent control that has this Callout as a tooltip |
Event is fired when the Callout window is closed.
Param | Type | Description |
---|---|---|
oControlEvent | sap.ui.base.Event | |
getSource | sap.ui.base.EventProvider | |
getParameters | object |
Method | Description |
---|---|
adjustPosition |
Adjust position of the already opened Callout window. Call this method each time when the size of the opened Callout window may be changed due to new or changed contents. |
attachBeforeOpen |
Attaches event handler When called, the context of the event handler (its Event is fired before a Callout is displayed. Call the preventDefault method of the event object to postpone opening. Application may use this event to start asynchronous Ajax call to load the Callout content |
attachClose |
Attaches event handler When called, the context of the event handler (its Event is fired when the Callout window is closed. |
attachOpen |
Attaches event handler When called, the context of the event handler (its The event is fired when the popup is opened. |
attachOpened |
Attaches event handler When called, the context of the event handler (its Is fired when the Callout has been opened |
close |
Closes Callout |
detachBeforeOpen |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
detachClose |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
detachOpen |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
detachOpened |
Detaches event handler The passed function and listener object must match the ones used for event registration. |
sap.ui.commons.CalloutBase.extend |
Creates a new subclass of class sap.ui.commons.CalloutBase with name
|
fireBeforeOpen |
Fires event beforeOpen to attached listeners. Listeners may prevent the default action of this event by calling the |
fireClose |
Fires event close to attached listeners. |
fireOpen |
Fires event open to attached listeners. |
fireOpened |
Fires event opened to attached listeners. |
sap.ui.commons.CalloutBase.getMetadata |
Returns a metadata object for class sap.ui.commons.CalloutBase. |
setPosition |
Set position of the Callout window relative to the parent control. This function automatically calculates and sets the correct offset, use it instead of |
Adjust position of the already opened Callout window. Call this method each time when the size of the opened Callout window may be changed due to new or changed contents.
Attaches event handler fnFunction
to the beforeOpen event of this sap.ui.commons.CalloutBase
.
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.commons.CalloutBase
itself.
Event is fired before a Callout is displayed. Call the preventDefault method of the event object to postpone opening. Application may use this event to start asynchronous Ajax call to load the Callout content
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 |
Attaches event handler fnFunction
to the close event of this sap.ui.commons.CalloutBase
.
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.commons.CalloutBase
itself.
Event is fired when the Callout window is closed.
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 |
Attaches event handler fnFunction
to the open event of this sap.ui.commons.CalloutBase
.
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.commons.CalloutBase
itself.
The event is fired when the popup is opened.
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 |
Attaches event handler fnFunction
to the opened event of this sap.ui.commons.CalloutBase
.
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.commons.CalloutBase
itself.
Is fired when the Callout has been opened
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 beforeOpen event of this sap.ui.commons.CalloutBase
.
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 |
Detaches event handler fnFunction
from the close event of this sap.ui.commons.CalloutBase
.
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 |
Detaches event handler fnFunction
from the open event of this sap.ui.commons.CalloutBase
.
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 |
Detaches event handler fnFunction
from the opened event of this sap.ui.commons.CalloutBase
.
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.ui.commons.CalloutBase 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.TooltipBase.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 beforeOpen to attached listeners.
Listeners may prevent the default action of this event by calling the preventDefault
method on the event object. The return value of this method indicates whether the default action should be executed.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
|
parent | sap.ui.core.Control |
Parent control that has this Callout as a tooltip |
Fires event close to attached listeners.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
Fires event open to attached listeners.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
|
parent | sap.ui.core.Control |
Parent control that has this Callout as a tooltip |
Fires event opened to attached listeners.
Param | Type | DefaultValue | Description |
---|---|---|---|
mParameters | object |
Parameters to pass along with the event |
Returns a metadata object for class sap.ui.commons.CalloutBase.
Set position of the Callout window relative to the parent control. This function automatically calculates and sets the correct offset, use it instead of setMyPosition/setAtPosition
.
Param | Type | DefaultValue | Description |
---|---|---|---|
myPosition | sap.ui.core.Dock |
docking position of the Callout |
|
atPosition | sap.ui.core.Dock |
docking position of the parent control |