sap.ui.layout.DynamicSideContent.extend(sClassName, oClassInfo?, FNMetaImpl?): function
Creates a new subclass of class sap.ui.layout.DynamicSideContent 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:
{string} | sClassName | Name of the class being created |
{object} | oClassInfo? | Object literal with information about the class |
{function} | FNMetaImpl? | Constructor function for the metadata object; if not given, it defaults to sap.ui.core.ElementMetadata |
Returns:
{function} | Created class / constructor function |
Returns a metadata object for class sap.ui.layout.DynamicSideContent.
Returns:
addMainContent(oControl): sap.m.DynamicSideContent
Adds a control to the main content area. Only the main content part in the aggregation is re-rendered.
Parameters:
{object} | oControl | Object to be added in the aggregation |
Returns:
{sap.m.DynamicSideContent} | this pointer for chaining |
addSideContent(oControl): sap.m.DynamicSideContent
Adds a control to the side content area. Only the side content part in the aggregation is re-rendered.
Parameters:
{object} | oControl | Object to be added in the aggregation |
Returns:
{sap.m.DynamicSideContent} | this pointer for chaining |
Attaches event handler
fnFunction
to the
breakpointChanged
event of this
sap.ui.layout.DynamicSideContent
.
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.layout.DynamicSideContent
itself.
Fires when the current breakpoint has been changed.
Parameters:
{object} | oData? | An application-specific payload object that will be passed to the event handler along with the event object when firing the event |
{function} | fnFunction | The function to be called when the event occurs |
{object} | oListener? | Context object to call the event handler with. Defaults to this sap.ui.layout.DynamicSideContent itself |
- Since:
- 1.32
Returns:
Destroys all the mainContent in the aggregation mainContent
.
Returns:
Destroys all the sideContent in the aggregation sideContent
.
Returns:
Detaches event handler
fnFunction
from the
breakpointChanged
event of this
sap.ui.layout.DynamicSideContent
.
The passed function and listener object must match the ones used for event registration.
Parameters:
{function} | fnFunction | The function to be called, when the event occurs |
{object} | oListener | Context object on which the given function had to be called |
- Since:
- 1.32
Returns:
Fires event
breakpointChanged
to attached listeners.
Expects the following event parameters:
currentBreakpoint
of type string
Parameters:
{Map} | mArguments? | The arguments to pass along with the event |
- Since:
- 1.32
Returns:
getContainerQuery(): boolean
Gets current value of property
containerQuery
.
If set to TRUE, then not the media Query (device screen size) but the size of the container, surrounding the control, defines the current range.
Default value is false
.
Returns:
{boolean} | Value of property containerQuery |
getCurrentBreakpoint(): String
Returns the breakpoint for the current state of the control.
Returns:
{String} | currentBreakpoint |
getEqualSplit(): boolean
Gets current value of property
equalSplit
.
Defines whether the control is in equal split mode. In this mode, the side and the main content take 50:50 percent of the container on all screen sizes except for phone, where the main and side contents are switching visibility using the toggle method.
Default value is false
.
Returns:
{boolean} | Value of property equalSplit |
Gets content of aggregation
mainContent
.
Main content controls.
Returns:
getShowMainContent(): boolean
Gets the value of showMainContent property.
Returns:
{boolean} | Side content visibility state |
getShowSideContent(): boolean
Gets the value of showSideContent property.
Returns:
{boolean} | Side content visibility state |
Gets content of aggregation
sideContent
.
Side content controls.
Returns:
Gets current value of property
sideContentFallDown
.
Determines on which breakpoints the side content falls down below the main content.
Default value is OnMinimumWidth
.
Returns:
Gets current value of property
sideContentPosition
.
Determines whether the side content is on the left or on the right side of the main content.
Default value is End
.
- Since:
- 1.36
Returns:
Gets current value of property
sideContentVisibility
.
Determines on which breakpoints the side content is visible.
Default value is ShowAboveS
.
Returns:
indexOfMainContent(oMainContent): int
Checks for the provided sap.ui.core.Control
in the aggregation mainContent
. and returns its index if found or -1 otherwise.
Parameters:
Returns:
{int} | The index of the provided control in the aggregation if found, or -1 otherwise |
indexOfSideContent(oSideContent): int
Checks for the provided sap.ui.core.Control
in the aggregation sideContent
. and returns its index if found or -1 otherwise.
Parameters:
Returns:
{int} | The index of the provided control in the aggregation if found, or -1 otherwise |
Inserts a mainContent into the aggregation mainContent
.
Parameters:
{sap.ui.core.Control} | oMainContent | the mainContent to insert; if empty, nothing is inserted |
{int} | iIndex | the 0 -based index the mainContent should be inserted at; for a negative value of iIndex , the mainContent is inserted at position 0; for a value greater than the current size of the aggregation, the mainContent is inserted at the last position |
Returns:
Inserts a sideContent into the aggregation sideContent
.
Parameters:
{sap.ui.core.Control} | oSideContent | the sideContent to insert; if empty, nothing is inserted |
{int} | iIndex | the 0 -based index the sideContent should be inserted at; for a negative value of iIndex , the sideContent is inserted at position 0; for a value greater than the current size of the aggregation, the sideContent is inserted at the last position |
Returns:
Removes all the controls from the aggregation
mainContent
.
Additionally, it unregisters them from the hosting UIArea.
Returns:
Removes all the controls from the aggregation
sideContent
.
Additionally, it unregisters them from the hosting UIArea.
Returns:
Removes a mainContent from the aggregation mainContent
.
Parameters:
Returns:
Removes a sideContent from the aggregation sideContent
.
Parameters:
Returns:
Sets a new value for property
containerQuery
.
If set to TRUE, then not the media Query (device screen size) but the size of the container, surrounding the control, defines the current range.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is false
.
Parameters:
{boolean} | bContainerQuery | New value for property containerQuery |
Returns:
setEqualSplit(bState?): sap.m.DynamicSideContent
Sets or unsets the page in equalSplit mode.
Parameters:
{boolean} | bState? | Determines if the page is set to equalSplit mode |
Returns:
{sap.m.DynamicSideContent} | this pointer for chaining |
setShowMainContent(bVisible, bSuppressVisualUpdate): sap.m.DynamicSideContent
Sets the showMainContent property.
Parameters:
{boolean} | bVisible | Determines if the main content part is visible |
{boolean} | bSuppressVisualUpdate | Determines if the visual state is updated |
Returns:
{sap.m.DynamicSideContent} | this pointer for chaining |
setShowSideContent(bVisible, bSuppressVisualUpdate): sap.m.DynamicSideContent
Sets the showSideContent property.
Parameters:
{boolean} | bVisible | Determines if the side content part is visible |
{boolean} | bSuppressVisualUpdate | Determines if the visual state is updated |
Returns:
{sap.m.DynamicSideContent} | this pointer for chaining |
Sets a new value for property
sideContentFallDown
.
Determines on which breakpoints the side content falls down below the main content.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is OnMinimumWidth
.
Parameters:
Returns:
Sets a new value for property
sideContentPosition
.
Determines whether the side content is on the left or on the right side of the main content.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is End
.
Parameters:
- Since:
- 1.36
Returns:
Sets a new value for property
sideContentVisibility
.
Determines on which breakpoints the side content is visible.
When called with a value of null
or undefined
, the default value of the property will be restored.
Default value is ShowAboveS
.
Parameters:
Returns:
toggle(): sap.m.DynamicSideContent
Used for the toggle button functionality. When the control is on a phone screen size only, one control area is visible. This helper method is used to implement a button/switch for changing between the main and side content areas. Only works if the current breakpoint is "S".
Returns:
{sap.m.DynamicSideContent} | this pointer for chaining |