class sap.m.SplitContainer

Control sample: sap.m.SplitContainer
Visiblity: public
UX Guidelines:
Implements: sap.ui.core.IPlaceholderSupport
Available since: N/A
Module: sap/m/SplitContainer
Application Component: CA-UI5-CTR

A container control that is used to display a master-detail view.

Overview

The SplitContainer divides the screen into two areas:

Both areas have separate headers and footer bars with navigation and actions.

Usage

SplitContainer should take the full width of the page in order to work properly.

When to use

When not to use

Responsive Behavior

On narrow screens, such as phones or tablet devices in portrait mode, the master list and the details are split into two separate pages. The user can navigate between the list and details, and see all the available information for each area.


Constructor

Constructor for a new SplitContainer.

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.SplitContainer(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


Properties

Name Type Default Value Description
backgroundColor string

Determines the background color of the SplitContainer. If set, this color overrides the default one, which is defined by the theme (should only be used when really required). Any configured background image will be placed above this colored background, but any theme adaptation in the Theme Designer will override this setting. Use the backgroundRepeat property to define whether this image should be stretched to cover the complete SplitContainer or whether it should be tiled.

Since: 1.11.2.

Visibility: public
backgroundImage sap.ui.core.URI

Sets the background image of the SplitContainer. When set, this image overrides the default background defined by the theme (should only be used when really required). This background image will be placed above any color set for the background, but any theme adaptation in the Theme Designer will override this image setting. Use the backgroundRepeat property to define whether this image should be stretched to cover the complete SplitContainer or whether it should be tiled.

Since: 1.11.2.

Visibility: public
backgroundOpacity float 1

Defines the opacity of the background image - between 0 (fully transparent) and 1 (fully opaque). This can be used to improve the content visibility by making the background image partly transparent.

Since: 1.11.2.

Visibility: public
backgroundRepeat boolean false

Defines whether the background image (if configured) is proportionally stretched to cover the whole SplitContainer (false) or whether it should be tiled (true).

Since: 1.11.2.

Visibility: public
defaultTransitionNameDetail string slide

Determines the type of the transition/animation to apply when to() is called without defining the transition to use. The default is "slide", other options are "fade", "show", and the names of any registered custom transitions.

Visibility: public
defaultTransitionNameMaster string slide

Determines the type of the transition/animation to apply when to() is called, without defining the transition to use. The default is "slide", other options are "fade", "show", and the names of any registered custom transitions.

Visibility: public
masterButtonText string

Determines the text displayed in master button, which has a default value "Navigation". This text is only displayed in iOS platform and the icon from the current page in detail area is displayed in the master button for the other platforms. The master button is shown/hidden depending on the orientation of the device and whether the master area is opened or not. SplitContainer manages the show/hide of the master button by itself only when the pages added to the detail area are sap.m.Page with built-in header or sap.m.Page with built-in header, which is wrapped by one or several sap.ui.core.mvc.View. Otherwise, the show/hide of master button needs to be managed by the application.

Visibility: public
masterButtonTooltip string

Specifies the tooltip of the master button. If the tooltip is not specified, the title of the page, which is displayed is the master part, is set as tooltip to the master button.

Since: 1.48.

Visibility: public
mode sap.m.SplitAppMode ShowHideMode

Defines whether the master page will always be displayed (in portrait and landscape mode - StretchCompressMode), or if it should be hidden when in portrait mode (ShowHideMode). Default is ShowHideMode. Other possible values are Hide (Master is always hidden) and Popover (master is displayed in popover).

Visibility: public

Aggregations

Default Aggregation:

Name Cardinality Type Description
_navDetail 0..1 sap.m.NavContainer

The detail navigation container managed by the SplitContainer control.

_navMaster 0..1 sap.m.NavContainer

The master navigation container managed by the SplitContainer control.

_navPopover 0..1 sap.m.Popover

A Popover managed by the SplitContainer control.

detailPages 0..n sap.ui.core.Control

Determines the content entities, between which the SplitContainer navigates in detail area. These can be of type sap.m.Page, sap.ui.core.mvc.View, sap.m.Carousel or any other control with fullscreen/page semantics. These aggregated controls receive navigation events like BeforeShow, they are documented in the pseudo interface sap.m.NavContainerChild.

masterPages 0..n sap.ui.core.Control

Determines the content entities, between which the SplitContainer navigates in master area. These can be of type sap.m.Page, sap.ui.core.mvc.View, sap.m.Carousel or any other control with fullscreen/page semantics. These aggregated controls receive navigation events like BeforeShow, they are documented in the pseudo interface sap.m.NavContainerChild.


Associations

Name Cardinality Type Description
initialDetail 0..1 sap.ui.core.Control

Sets the initial detail page, which is displayed on application launch.

initialMaster 0..1 sap.ui.core.Control

Sets the initial master page, which is displayed on application launch.


Events Overview

Event Description
afterDetailNavigate

Fires when navigation between two pages in detail area has completed. NOTE: In case of animated transitions this event is fired with some delay after the "navigate" event.

afterMasterClose

Fires when the master area is fully closed after the animation (if any).

afterMasterNavigate

Fires when navigation between two pages in master area has completed. NOTE: In case of animated transitions this event is fired with some delay after the navigate event.

afterMasterOpen

Fires when the master area is fully opened after animation if any.

beforeMasterClose

Fires before the master area is closed.

beforeMasterOpen

Fires before the master area is opened.

detailNavigate

Fires when navigation between two pages in detail area has been triggered. The transition (if any) to the new page has not started yet. NOTE: This event can be aborted by the application with preventDefault(), which means that there will be no navigation.

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

masterButton

Fires when a Master Button needs to be shown or hidden. This is necessary for custom headers when the SplitContainer control does not handle the placement of the master button automatically.

masterNavigate

Fires when navigation between two pages in master area has been triggered. The transition (if any) to the new page has not started yet. This event can be aborted by the application with preventDefault(), which means that there will be no navigation.

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

afterDetailNavigate

Fires when navigation between two pages in detail area has completed. NOTE: In case of animated transitions this event is fired with some delay after the "navigate" event.

Param Type Description
oControlEvent sap.ui.base.Event
getSource sap.ui.base.EventProvider
getParameters object
from sap.ui.core.Control

The page, which had been displayed before navigation.

fromId string

The ID of the page, which had been displayed before navigation.

to sap.ui.core.Control

The page, which is now displayed after navigation.

toId string

The ID of the page, which is now displayed after navigation.

firstTime boolean

Determines whether the "to" page (more precisely: a control with the ID of the page, which has been navigated to) has not been displayed/navigated to before.

isTo boolean

Determines whether was a forward navigation, triggered by to().

isBack boolean

Determines whether this was a back navigation, triggered by back().

isBackToTop boolean

Determines whether this was a navigation to the root page, triggered by backToTop().

isBackToPage boolean

Determines whether this was a navigation to a specific page, triggered by backToPage().

Since: 1.7.2.

direction string

Determines how the navigation was triggered, possible values are "to", "back", "backToPage", and "backToTop".

afterMasterClose

Fires when the master area is fully closed after the animation (if any).

Param Type Description
oControlEvent sap.ui.base.Event
getSource sap.ui.base.EventProvider
getParameters object

afterMasterNavigate

Fires when navigation between two pages in master area has completed. NOTE: In case of animated transitions this event is fired with some delay after the navigate event.

Param Type Description
oControlEvent sap.ui.base.Event
getSource sap.ui.base.EventProvider
getParameters object
from sap.ui.core.Control

The page, which had been displayed before navigation.

fromId string

The ID of the page, which had been displayed before navigation.

to sap.ui.core.Control

The page, which is now displayed after navigation.

toId string

The ID of the page, which is now displayed after navigation.

firstTime boolean

Whether the "to" page (more precisely: a control with the ID of the page, which has been navigated to) has not been displayed/navigated to before.

isTo boolean

Determines whether was a forward navigation, triggered by to().

isBack boolean

Determines whether this was a back navigation, triggered by back().

isBackToTop boolean

Determines whether this was a navigation to the root page, triggered by backToTop().

isBackToPage boolean

Determines whether this was a navigation to a specific page, triggered by backToPage().

Since: 1.7.2.

direction string

Determines how the navigation was triggered, possible values are "to", "back", "backToPage", and "backToTop".

afterMasterOpen

Fires when the master area is fully opened after animation if any.

Param Type Description
oControlEvent sap.ui.base.Event
getSource sap.ui.base.EventProvider
getParameters object

beforeMasterClose

Fires before the master area is closed.

Param Type Description
oControlEvent sap.ui.base.Event
getSource sap.ui.base.EventProvider
getParameters object

beforeMasterOpen

Fires before the master area is opened.

Param Type Description
oControlEvent sap.ui.base.Event
getSource sap.ui.base.EventProvider
getParameters object

detailNavigate

Fires when navigation between two pages in detail area has been triggered. The transition (if any) to the new page has not started yet. NOTE: This event can be aborted by the application with preventDefault(), which means that there will be no navigation.

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
from sap.ui.core.Control

The page, which was displayed before the current navigation.

fromId string

The ID of the page, which was displayed before the current navigation.

to sap.ui.core.Control

The page, which will be displayed after the current navigation.

toId string

The ID of the page, which will be displayed after the current navigation.

firstTime boolean

Determines whether the "to" page (more precisely: a control with the ID of the page, which is currently navigated to) has not been displayed/navigated to before.

isTo boolean

Determines whether this is a forward navigation, triggered by to().

isBack boolean

Determines whether this is a back navigation, triggered by back().

isBackToTop boolean

Determines whether this is a navigation to the root page, triggered by backToTop().

isBackToPage boolean

Determines whether this was a navigation to a specific page, triggered by backToPage().

Since: 1.7.2.

direction string

Determines how the navigation was triggered, possible values are "to", "back", "backToPage", and "backToTop".

masterButton

Fires when a Master Button needs to be shown or hidden. This is necessary for custom headers when the SplitContainer control does not handle the placement of the master button automatically.

Param Type Description
oControlEvent sap.ui.base.Event
getSource sap.ui.base.EventProvider
getParameters object

masterNavigate

Fires when navigation between two pages in master area has been triggered. The transition (if any) to the new page has not started yet. This event can be aborted by the application with preventDefault(), which means that there will be no navigation.

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
from sap.ui.core.Control

The page, which was displayed before the current navigation.

fromId string

The ID of the page, which was displayed before the current navigation.

to sap.ui.core.Control

The page, which will be displayed after the current navigation.

toId string

The ID of the page, which will be displayed after the current navigation.

firstTime boolean

Determines whether the "to" page (more precisely: a control with the ID of the page, which is currently being navigated to) has not been displayed/navigated to before.

isTo boolean

Determines whether this is a forward navigation, triggered by to().

isBack boolean

Determines whether this is a back navigation, triggered by back().

isBackToTop boolean

Determines whether this is a navigation to the root page, triggered by backToTop().

isBackToPage boolean

Determines whether this was a navigation to a specific page, triggered by backToPage().

Since: 1.7.2.

direction string

Determines how the navigation was triggered, possible values are "to", "back", "backToPage", and "backToTop".


Methods Overview

Method Description
addDetailPage

Adds some detailPage to the aggregation detailPages.

addMasterPage

Adds some masterPage to the aggregation masterPages.

addPage

Adds a content entity either to master area or detail area depending on the master parameter.

The method is provided mainly for providing API consistency between sap.m.SplitContainer and sap.m.App. So that the same code line can be reused.

attachAfterDetailNavigate

Attaches event handler fnFunction to the afterDetailNavigate event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when navigation between two pages in detail area has completed. NOTE: In case of animated transitions this event is fired with some delay after the "navigate" event.

attachAfterMasterClose

Attaches event handler fnFunction to the afterMasterClose event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when the master area is fully closed after the animation (if any).

attachAfterMasterNavigate

Attaches event handler fnFunction to the afterMasterNavigate event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when navigation between two pages in master area has completed. NOTE: In case of animated transitions this event is fired with some delay after the navigate event.

attachAfterMasterOpen

Attaches event handler fnFunction to the afterMasterOpen event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when the master area is fully opened after animation if any.

attachBeforeMasterClose

Attaches event handler fnFunction to the beforeMasterClose event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires before the master area is closed.

attachBeforeMasterOpen

Attaches event handler fnFunction to the beforeMasterOpen event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires before the master area is opened.

attachDetailNavigate

Attaches event handler fnFunction to the detailNavigate event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when navigation between two pages in detail area has been triggered. The transition (if any) to the new page has not started yet. NOTE: This event can be aborted by the application with preventDefault(), which means that there will be no navigation.

attachMasterButton

Attaches event handler fnFunction to the masterButton event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when a Master Button needs to be shown or hidden. This is necessary for custom headers when the SplitContainer control does not handle the placement of the master button automatically.

attachMasterNavigate

Attaches event handler fnFunction to the masterNavigate event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when navigation between two pages in master area has been triggered. The transition (if any) to the new page has not started yet. This event can be aborted by the application with preventDefault(), which means that there will be no navigation.

backDetail

Navigates back to the previous detail page found in the history.

backMaster

Navigates back to the previous master page which is found in the history.

backToPage

Navigates back to the nearest previous page in the SplitContainer history with the given ID (if there is no such page among the previous pages, nothing happens). The transition effect, which had been used to get to the current page is inverted and used for this navigation.

Calling this navigation method, first triggers the (cancelable) navigate event on the SplitContainer, then the BeforeHide pseudo event on the source page, BeforeFirstShow (if applicable), and BeforeShow on the target page. Later, after the transition has completed, the AfterShow pseudo event is triggered on the target page and AfterHide - on the page, which has been left. The given backData object is available in the BeforeFirstShow, BeforeShow, and AfterShow event objects as data property. The original "data" object from the "to" navigation is also available in these event objects.

backToTopDetail

Navigates back to the initial/top level of Detail (this is the element aggregated as initialPage, or the first added element). NOTE: If already on the initial page, nothing happens. The transition effect which had been used to get to the current page is inverted and used for this navigation.

backToTopMaster

Navigates back to the initial/top level of Master (this is the element aggregated as "initialPage", or the first added element). NOTE: If already on the initial page, nothing happens. The transition effect which had been used to get to the current page is inverted and used for this navigation.

destroyDetailPages

Destroys all the detailPages in the aggregation detailPages.

destroyMasterPages

Destroys all the masterPages in the aggregation masterPages.

detachAfterDetailNavigate

Detaches event handler fnFunction from the afterDetailNavigate event of this sap.m.SplitContainer.

The passed function and listener object must match the ones used for event registration.

detachAfterMasterClose

Detaches event handler fnFunction from the afterMasterClose event of this sap.m.SplitContainer.

The passed function and listener object must match the ones used for event registration.

detachAfterMasterNavigate

Detaches event handler fnFunction from the afterMasterNavigate event of this sap.m.SplitContainer.

The passed function and listener object must match the ones used for event registration.

detachAfterMasterOpen

Detaches event handler fnFunction from the afterMasterOpen event of this sap.m.SplitContainer.

The passed function and listener object must match the ones used for event registration.

detachBeforeMasterClose

Detaches event handler fnFunction from the beforeMasterClose event of this sap.m.SplitContainer.

The passed function and listener object must match the ones used for event registration.

detachBeforeMasterOpen

Detaches event handler fnFunction from the beforeMasterOpen event of this sap.m.SplitContainer.

The passed function and listener object must match the ones used for event registration.

detachDetailNavigate

Detaches event handler fnFunction from the detailNavigate event of this sap.m.SplitContainer.

The passed function and listener object must match the ones used for event registration.

detachMasterButton

Detaches event handler fnFunction from the masterButton event of this sap.m.SplitContainer.

The passed function and listener object must match the ones used for event registration.

detachMasterNavigate

Detaches event handler fnFunction from the masterNavigate event of this sap.m.SplitContainer.

The passed function and listener object must match the ones used for event registration.

sap.m.SplitContainer.extend

Creates a new subclass of class sap.m.SplitContainer 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.

fireAfterDetailNavigate

Fires event afterDetailNavigate to attached listeners.

fireAfterMasterClose

Fires event afterMasterClose to attached listeners.

fireAfterMasterNavigate

Fires event afterMasterNavigate to attached listeners.

fireAfterMasterOpen

Fires event afterMasterOpen to attached listeners.

fireBeforeMasterClose

Fires event beforeMasterClose to attached listeners.

fireBeforeMasterOpen

Fires event beforeMasterOpen to attached listeners.

fireDetailNavigate

Fires event detailNavigate 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.

fireMasterButton

Fires event masterButton to attached listeners.

fireMasterNavigate

Fires event masterNavigate 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.

getBackgroundColor

Gets current value of property backgroundColor.

Determines the background color of the SplitContainer. If set, this color overrides the default one, which is defined by the theme (should only be used when really required). Any configured background image will be placed above this colored background, but any theme adaptation in the Theme Designer will override this setting. Use the backgroundRepeat property to define whether this image should be stretched to cover the complete SplitContainer or whether it should be tiled.

getBackgroundImage

Gets current value of property backgroundImage.

Sets the background image of the SplitContainer. When set, this image overrides the default background defined by the theme (should only be used when really required). This background image will be placed above any color set for the background, but any theme adaptation in the Theme Designer will override this image setting. Use the backgroundRepeat property to define whether this image should be stretched to cover the complete SplitContainer or whether it should be tiled.

getBackgroundOpacity

Gets current value of property backgroundOpacity.

Defines the opacity of the background image - between 0 (fully transparent) and 1 (fully opaque). This can be used to improve the content visibility by making the background image partly transparent.

Default value is 1.

getBackgroundRepeat

Gets current value of property backgroundRepeat.

Defines whether the background image (if configured) is proportionally stretched to cover the whole SplitContainer (false) or whether it should be tiled (true).

Default value is false.

getCurrentDetailPage

Returns the current displayed detail page.

getCurrentMasterPage

Returns the current displayed master page.

getCurrentPage

Returns the currently displayed page either in master area or in detail area. When the parameter is set to true, the current page in master area is returned, otherwise, the current page in detail area is returned.

This method is provided mainly for API consistency between sap.m.SplitContainer and sap.m.App, so that the same code line can be reused.

getDefaultTransitionNameDetail

Gets current value of property defaultTransitionNameDetail.

Determines the type of the transition/animation to apply when to() is called without defining the transition to use. The default is "slide", other options are "fade", "show", and the names of any registered custom transitions.

Default value is "slide".

getDefaultTransitionNameMaster

Gets current value of property defaultTransitionNameMaster.

Determines the type of the transition/animation to apply when to() is called, without defining the transition to use. The default is "slide", other options are "fade", "show", and the names of any registered custom transitions.

Default value is "slide".

getDetailPage

Returns the page with the given ID in detail area. If there's no page that has the given ID, null is returned.

getDetailPages

Gets content of aggregation detailPages.

Determines the content entities, between which the SplitContainer navigates in detail area. These can be of type sap.m.Page, sap.ui.core.mvc.View, sap.m.Carousel or any other control with fullscreen/page semantics. These aggregated controls receive navigation events like BeforeShow, they are documented in the pseudo interface sap.m.NavContainerChild.

getInitialDetail

ID of the element which is the current target of the association initialDetail, or null.

getInitialMaster

ID of the element which is the current target of the association initialMaster, or null.

getMasterButtonText

Gets current value of property masterButtonText.

Determines the text displayed in master button, which has a default value "Navigation". This text is only displayed in iOS platform and the icon from the current page in detail area is displayed in the master button for the other platforms. The master button is shown/hidden depending on the orientation of the device and whether the master area is opened or not. SplitContainer manages the show/hide of the master button by itself only when the pages added to the detail area are sap.m.Page with built-in header or sap.m.Page with built-in header, which is wrapped by one or several sap.ui.core.mvc.View. Otherwise, the show/hide of master button needs to be managed by the application.

getMasterButtonTooltip

Gets current value of property masterButtonTooltip.

Specifies the tooltip of the master button. If the tooltip is not specified, the title of the page, which is displayed is the master part, is set as tooltip to the master button.

getMasterPage

Returns the page with the given ID in master area (if there's no page that has the given ID, null is returned).

getMasterPages

Gets content of aggregation masterPages.

Determines the content entities, between which the SplitContainer navigates in master area. These can be of type sap.m.Page, sap.ui.core.mvc.View, sap.m.Carousel or any other control with fullscreen/page semantics. These aggregated controls receive navigation events like BeforeShow, they are documented in the pseudo interface sap.m.NavContainerChild.

sap.m.SplitContainer.getMetadata

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

getMode

Gets current value of property mode.

Defines whether the master page will always be displayed (in portrait and landscape mode - StretchCompressMode), or if it should be hidden when in portrait mode (ShowHideMode). Default is ShowHideMode. Other possible values are Hide (Master is always hidden) and Popover (master is displayed in popover).

Default value is ShowHideMode.

getPage

Returns the page with the given ID from either master area, or detail area depending on the master parameter (if there's no page that has the given ID, null is returned).

getPreviousPage

Returns the previous page (the page, from which the user drilled down to the current page with to()). Note: this is not the page, which the user has seen before, but the page which is the target of the next back() navigation. If there is no previous page, "undefined" is returned.

hideMaster

Used to hide the master page when in ShowHideMode and the device is in portrait mode.

hidePlaceholder

Hides the placeholder on the corresponding column for the provided aggregation name.

indexOfDetailPage

Checks for the provided sap.ui.core.Control in the aggregation detailPages. and returns its index if found or -1 otherwise.

indexOfMasterPage

Checks for the provided sap.ui.core.Control in the aggregation masterPages. and returns its index if found or -1 otherwise.

insertDetailPage

Inserts a detailPage into the aggregation detailPages.

insertMasterPage

Inserts a masterPage into the aggregation masterPages.

insertPreviousPage

Inserts the page/control with the specified ID into the navigation history stack of the NavContainer.

This can be used for deep-linking when the user directly reached a drilldown detail page using a bookmark and then wants to navigate up in the drilldown hierarchy. Normally, such a back navigation would not be possible as there is no previous page in the SplitContainer's history stack.

isMasterShown

Returns whether master area is currently displayed on the screen. In desktop browser or tablet, this method returns true when master area is displayed on the screen, regardless if in portrait or landscape mode. On mobile phone devices, this method returns true when the currently displayed page is from the pages, which are added to the master area, otherwise, it returns false.

needPlaceholder

Checks whether a placeholder is needed by comparing the currently displayed page with the page object that is going to be displayed. If they are the same, no placeholder needs to be shown.

removeAllDetailPages

Removes all the controls from the aggregation detailPages.

Additionally, it unregisters them from the hosting UIArea.

removeAllMasterPages

Removes all the controls from the aggregation masterPages.

Additionally, it unregisters them from the hosting UIArea.

removeDetailPage

Removes a detailPage from the aggregation detailPages.

removeMasterPage

Removes a masterPage from the aggregation masterPages.

setBackgroundColor

Sets a new value for property backgroundColor.

Determines the background color of the SplitContainer. If set, this color overrides the default one, which is defined by the theme (should only be used when really required). Any configured background image will be placed above this colored background, but any theme adaptation in the Theme Designer will override this setting. Use the backgroundRepeat property to define whether this image should be stretched to cover the complete SplitContainer or whether it should be tiled.

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

setBackgroundImage

Sets a new value for property backgroundImage.

Sets the background image of the SplitContainer. When set, this image overrides the default background defined by the theme (should only be used when really required). This background image will be placed above any color set for the background, but any theme adaptation in the Theme Designer will override this image setting. Use the backgroundRepeat property to define whether this image should be stretched to cover the complete SplitContainer or whether it should be tiled.

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

setBackgroundOpacity

Sets a new value for property backgroundOpacity.

Defines the opacity of the background image - between 0 (fully transparent) and 1 (fully opaque). This can be used to improve the content visibility by making the background image partly transparent.

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

Default value is 1.

setBackgroundRepeat

Sets a new value for property backgroundRepeat.

Defines whether the background image (if configured) is proportionally stretched to cover the whole SplitContainer (false) or whether it should be tiled (true).

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

Default value is false.

setDefaultTransitionNameDetail

Sets a new value for property defaultTransitionNameDetail.

Determines the type of the transition/animation to apply when to() is called without defining the transition to use. The default is "slide", other options are "fade", "show", and the names of any registered custom transitions.

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

Default value is "slide".

setDefaultTransitionNameMaster

Sets a new value for property defaultTransitionNameMaster.

Determines the type of the transition/animation to apply when to() is called, without defining the transition to use. The default is "slide", other options are "fade", "show", and the names of any registered custom transitions.

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

Default value is "slide".

setInitialDetail

Sets the associated initialDetail.

setInitialMaster

Sets the associated initialMaster.

setMasterButtonText

Sets a new value for property masterButtonText.

Determines the text displayed in master button, which has a default value "Navigation". This text is only displayed in iOS platform and the icon from the current page in detail area is displayed in the master button for the other platforms. The master button is shown/hidden depending on the orientation of the device and whether the master area is opened or not. SplitContainer manages the show/hide of the master button by itself only when the pages added to the detail area are sap.m.Page with built-in header or sap.m.Page with built-in header, which is wrapped by one or several sap.ui.core.mvc.View. Otherwise, the show/hide of master button needs to be managed by the application.

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

setMasterButtonTooltip

Sets a new value for property masterButtonTooltip.

Specifies the tooltip of the master button. If the tooltip is not specified, the title of the page, which is displayed is the master part, is set as tooltip to the master button.

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

setMode

Sets a new value for property mode.

Defines whether the master page will always be displayed (in portrait and landscape mode - StretchCompressMode), or if it should be hidden when in portrait mode (ShowHideMode). Default is ShowHideMode. Other possible values are Hide (Master is always hidden) and Popover (master is displayed in popover).

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

Default value is ShowHideMode.

showMaster

Used to make the master page visible when in ShowHideMode and the device is in portrait mode.

showPlaceholder

Shows the placeholder on the corresponding column for the provided aggregation name.

to

Navigates to the given page inside the SplitContainer. The navigation is done inside the master area if the page has been added, otherwise, it tries to do the page navigation in the detail area.

toDetail

Navigates to a given detail page.

toMaster

Navigates to a given master page.

addDetailPage

Adds some detailPage to the aggregation detailPages.

Param Type DefaultValue Description
oDetailPage sap.ui.core.Control

The detailPage to add; if empty, nothing is inserted

addMasterPage

Adds some masterPage to the aggregation masterPages.

Param Type DefaultValue Description
oMasterPage sap.ui.core.Control

The masterPage to add; if empty, nothing is inserted

addPage

Adds a content entity either to master area or detail area depending on the master parameter.

The method is provided mainly for providing API consistency between sap.m.SplitContainer and sap.m.App. So that the same code line can be reused.

Param Type DefaultValue Description
oPage sap.ui.core.Control

The content entities between which this SplitContainer navigates in either master area or detail area depending on the master parameter. These can be of type sap.m.Page, sap.ui.core.mvc.View, sap.m.Carousel or any other control with fullscreen/page semantics.

bMaster boolean

States if the page should be added to the master area. If it's set to false, the page is added to detail area.

attachAfterDetailNavigate

Attaches event handler fnFunction to the afterDetailNavigate event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when navigation between two pages in detail area has completed. NOTE: In case of animated transitions this event is fired with some delay after the "navigate" event.

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 sap.m.SplitContainer itself

attachAfterMasterClose

Attaches event handler fnFunction to the afterMasterClose event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when the master area is fully closed after the animation (if any).

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 sap.m.SplitContainer itself

attachAfterMasterNavigate

Attaches event handler fnFunction to the afterMasterNavigate event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when navigation between two pages in master area has completed. NOTE: In case of animated transitions this event is fired with some delay after the navigate event.

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 sap.m.SplitContainer itself

attachAfterMasterOpen

Attaches event handler fnFunction to the afterMasterOpen event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when the master area is fully opened after animation if any.

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 sap.m.SplitContainer itself

attachBeforeMasterClose

Attaches event handler fnFunction to the beforeMasterClose event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires before the master area 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 sap.m.SplitContainer itself

attachBeforeMasterOpen

Attaches event handler fnFunction to the beforeMasterOpen event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires before the master area 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 sap.m.SplitContainer itself

attachDetailNavigate

Attaches event handler fnFunction to the detailNavigate event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when navigation between two pages in detail area has been triggered. The transition (if any) to the new page has not started yet. NOTE: This event can be aborted by the application with preventDefault(), which means that there will be no navigation.

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 sap.m.SplitContainer itself

attachMasterButton

Attaches event handler fnFunction to the masterButton event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when a Master Button needs to be shown or hidden. This is necessary for custom headers when the SplitContainer control does not handle the placement of the master button automatically.

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 sap.m.SplitContainer itself

attachMasterNavigate

Attaches event handler fnFunction to the masterNavigate event of this sap.m.SplitContainer.

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.SplitContainer itself.

Fires when navigation between two pages in master area has been triggered. The transition (if any) to the new page has not started yet. This event can be aborted by the application with preventDefault(), which means that there will be no navigation.

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 sap.m.SplitContainer itself

backDetail

Navigates back to the previous detail page found in the history.

Param Type DefaultValue Description
oBackData object

This optional object can carry any payload data which should be made available to the target page of the back navigation. The event on the target page will contain this data object as backData property. (The original data from the to() navigation will still be available as data property.)

In scenarios where the entity triggering the navigation can or should not directly initialize the target page, it can fill this object and the target page itself (or a listener on it) can take over the initialization, using the given data. For back navigation this can be used, for example, when returning from a detail page to transfer any settings done there.

When the transitionParameters object is used, this data object must also be given (either as object or as null) in order to have a proper parameter order.

oTransitionParameter object

This optional object can give additional information to the transition function, like the DOM element, which triggered the transition or the desired transition duration. The animation type can NOT be selected here - it is always the inverse of the "to" navigation.

In order to use the transitionParameters property, the data property must be used (at least "null" must be given) for a proper parameter order.

NOTE: it depends on the transition function how the object should be structured and which parameters are actually used to influence the transition.

backMaster

Navigates back to the previous master page which is found in the history.

Param Type DefaultValue Description
oBackData object

This optional object can carry any payload data which should be made available to the target page of the back navigation. The event on the target page will contain this data object as backData property (the original data from the to() navigation will still be available as data property).

In scenarios where the entity triggering the navigation can or should not directly initialize the target page, it can fill this object and the target page itself (or a listener on it) can take over the initialization, using the given data. For back navigation this can be used, for example, when returning from a detail page to transfer any settings done there.

When the transitionParameters object is used, this data object must also be given (either as object or as null) in order to have a proper parameter order.

oTransitionParameter object

This optional object can give additional information to the transition function, like the DOM element, which triggered the transition or the desired transition duration. The animation type can NOT be selected here - it is always the inverse of the "to" navigation.

In order to use the transitionParameters property, the data property must be used (at least "null" must be given) for a proper parameter order.

NOTE: it depends on the transition function how the object should be structured and which parameters are actually used to influence the transition.

backToPage

Navigates back to the nearest previous page in the SplitContainer history with the given ID (if there is no such page among the previous pages, nothing happens). The transition effect, which had been used to get to the current page is inverted and used for this navigation.

Calling this navigation method, first triggers the (cancelable) navigate event on the SplitContainer, then the BeforeHide pseudo event on the source page, BeforeFirstShow (if applicable), and BeforeShow on the target page. Later, after the transition has completed, the AfterShow pseudo event is triggered on the target page and AfterHide - on the page, which has been left. The given backData object is available in the BeforeFirstShow, BeforeShow, and AfterShow event objects as data property. The original "data" object from the "to" navigation is also available in these event objects.

Param Type DefaultValue Description
sPageId string

The screen to which is being navigated to. The ID or the control itself can be given.

oBackData object

This optional object can carry any payload data which should be made available to the target page of the back navigation. The event on the target page will contain this data object as backData property. (the original data from the to() navigation will still be available as data property).

In scenarios, where the entity triggering the navigation can't or shouldn't directly initialize the target page, it can fill this object and the target page itself (or a listener on it) can take over the initialization, using the given data. For back navigation this can be used, for example, when returning from a detail page to transfer any settings done there.

When the transitionParameters object is used, this data object must also be given (either as object or as null) in order to have a proper parameter order.

oTransitionParameters object

This optional object can give additional information to the transition function, like the DOM element, which triggered the transition or the desired transition duration. The animation type can NOT be selected here - it is always the inverse of the "to" navigation.

In order to use the transitionParameters property, the data property must be used (at least "null" must be given) for a proper parameter order.

NOTE: it depends on the transition function how the object should be structured and which parameters are actually used to influence the transition.

backToTopDetail

Navigates back to the initial/top level of Detail (this is the element aggregated as initialPage, or the first added element). NOTE: If already on the initial page, nothing happens. The transition effect which had been used to get to the current page is inverted and used for this navigation.

Param Type DefaultValue Description
oBackData object

This optional object can carry any payload data which should be made available to the target page of the back navigation. The event on the target page will contain this data object as backData property (the original data from the to() navigation will still be available as data property).

In scenarios where the entity triggering the navigation can or should not directly initialize the target page, it can fill this object and the target page itself (or a listener on it) can take over the initialization, using the given data. For back navigation this can be used, for example, when returning from a detail page to transfer any settings done there.

When the transitionParameters object is used, this data object must also be given (either as object or as null) in order to have a proper parameter order.

oTransitionParameter object

This optional object can give additional information to the transition function, like the DOM element, which triggered the transition or the desired transition duration. The animation type can NOT be selected here - it is always the inverse of the "to" navigation.

In order to use the transitionParameters property, the data property must be used (at least "null" must be given) for a proper parameter order.

NOTE: it depends on the transition function how the object should be structured and which parameters are actually used to influence the transition.

backToTopMaster

Navigates back to the initial/top level of Master (this is the element aggregated as "initialPage", or the first added element). NOTE: If already on the initial page, nothing happens. The transition effect which had been used to get to the current page is inverted and used for this navigation.

Param Type DefaultValue Description
oBackData object

This optional object can carry any payload data which should be made available to the target page of the back navigation. The event on the target page will contain this data object as "backData" property. (The original data from the "to()" navigation will still be available as "data" property.)

In scenarios where the entity triggering the navigation can or should not directly initialize the target page, it can fill this object and the target page itself (or a listener on it) can take over the initialization, using the given data. For back navigation this can be used e.g. when returning from a detail page to transfer any settings done there.

When the "transitionParameters" object is used, this "data" object must also be given (either as object or as null) in order to have a proper parameter order.

oTransitionParameter object

This optional object can give additional information to the transition function, like the DOM element which triggered the transition or the desired transition duration. The animation type can NOT be selected here - it is always the inverse of the "to" navigation.

In order to use the transitionParameters property, the data property must be used (at least "null" must be given) for a proper parameter order.

NOTE: it depends on the transition function how the object should be structured and which parameters are actually used to influence the transition.

destroyDetailPages

Destroys all the detailPages in the aggregation detailPages.

destroyMasterPages

Destroys all the masterPages in the aggregation masterPages.

detachAfterDetailNavigate

Detaches event handler fnFunction from the afterDetailNavigate event of this sap.m.SplitContainer.

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

detachAfterMasterClose

Detaches event handler fnFunction from the afterMasterClose event of this sap.m.SplitContainer.

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

detachAfterMasterNavigate

Detaches event handler fnFunction from the afterMasterNavigate event of this sap.m.SplitContainer.

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

detachAfterMasterOpen

Detaches event handler fnFunction from the afterMasterOpen event of this sap.m.SplitContainer.

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

detachBeforeMasterClose

Detaches event handler fnFunction from the beforeMasterClose event of this sap.m.SplitContainer.

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

detachBeforeMasterOpen

Detaches event handler fnFunction from the beforeMasterOpen event of this sap.m.SplitContainer.

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

detachDetailNavigate

Detaches event handler fnFunction from the detailNavigate event of this sap.m.SplitContainer.

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

detachMasterButton

Detaches event handler fnFunction from the masterButton event of this sap.m.SplitContainer.

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

detachMasterNavigate

Detaches event handler fnFunction from the masterNavigate event of this sap.m.SplitContainer.

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

sap.m.SplitContainer.extend

Creates a new subclass of class sap.m.SplitContainer 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.

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

fireAfterDetailNavigate

Fires event afterDetailNavigate to attached listeners.

Param Type DefaultValue Description
mParameters object

Parameters to pass along with the event

from sap.ui.core.Control

The page, which had been displayed before navigation.

fromId string

The ID of the page, which had been displayed before navigation.

to sap.ui.core.Control

The page, which is now displayed after navigation.

toId string

The ID of the page, which is now displayed after navigation.

firstTime boolean

Determines whether the "to" page (more precisely: a control with the ID of the page, which has been navigated to) has not been displayed/navigated to before.

isTo boolean

Determines whether was a forward navigation, triggered by to().

isBack boolean

Determines whether this was a back navigation, triggered by back().

isBackToTop boolean

Determines whether this was a navigation to the root page, triggered by backToTop().

isBackToPage boolean

Determines whether this was a navigation to a specific page, triggered by backToPage().

direction string

Determines how the navigation was triggered, possible values are "to", "back", "backToPage", and "backToTop".

fireAfterMasterClose

Fires event afterMasterClose to attached listeners.

Param Type DefaultValue Description
mParameters object

Parameters to pass along with the event

fireAfterMasterNavigate

Fires event afterMasterNavigate to attached listeners.

Param Type DefaultValue Description
mParameters object

Parameters to pass along with the event

from sap.ui.core.Control

The page, which had been displayed before navigation.

fromId string

The ID of the page, which had been displayed before navigation.

to sap.ui.core.Control

The page, which is now displayed after navigation.

toId string

The ID of the page, which is now displayed after navigation.

firstTime boolean

Whether the "to" page (more precisely: a control with the ID of the page, which has been navigated to) has not been displayed/navigated to before.

isTo boolean

Determines whether was a forward navigation, triggered by to().

isBack boolean

Determines whether this was a back navigation, triggered by back().

isBackToTop boolean

Determines whether this was a navigation to the root page, triggered by backToTop().

isBackToPage boolean

Determines whether this was a navigation to a specific page, triggered by backToPage().

direction string

Determines how the navigation was triggered, possible values are "to", "back", "backToPage", and "backToTop".

fireAfterMasterOpen

Fires event afterMasterOpen to attached listeners.

Param Type DefaultValue Description
mParameters object

Parameters to pass along with the event

fireBeforeMasterClose

Fires event beforeMasterClose to attached listeners.

Param Type DefaultValue Description
mParameters object

Parameters to pass along with the event

fireBeforeMasterOpen

Fires event beforeMasterOpen to attached listeners.

Param Type DefaultValue Description
mParameters object

Parameters to pass along with the event

fireDetailNavigate

Fires event detailNavigate 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

from sap.ui.core.Control

The page, which was displayed before the current navigation.

fromId string

The ID of the page, which was displayed before the current navigation.

to sap.ui.core.Control

The page, which will be displayed after the current navigation.

toId string

The ID of the page, which will be displayed after the current navigation.

firstTime boolean

Determines whether the "to" page (more precisely: a control with the ID of the page, which is currently navigated to) has not been displayed/navigated to before.

isTo boolean

Determines whether this is a forward navigation, triggered by to().

isBack boolean

Determines whether this is a back navigation, triggered by back().

isBackToTop boolean

Determines whether this is a navigation to the root page, triggered by backToTop().

isBackToPage boolean

Determines whether this was a navigation to a specific page, triggered by backToPage().

direction string

Determines how the navigation was triggered, possible values are "to", "back", "backToPage", and "backToTop".

fireMasterButton

Fires event masterButton to attached listeners.

Param Type DefaultValue Description
mParameters object

Parameters to pass along with the event

fireMasterNavigate

Fires event masterNavigate 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

from sap.ui.core.Control

The page, which was displayed before the current navigation.

fromId string

The ID of the page, which was displayed before the current navigation.

to sap.ui.core.Control

The page, which will be displayed after the current navigation.

toId string

The ID of the page, which will be displayed after the current navigation.

firstTime boolean

Determines whether the "to" page (more precisely: a control with the ID of the page, which is currently being navigated to) has not been displayed/navigated to before.

isTo boolean

Determines whether this is a forward navigation, triggered by to().

isBack boolean

Determines whether this is a back navigation, triggered by back().

isBackToTop boolean

Determines whether this is a navigation to the root page, triggered by backToTop().

isBackToPage boolean

Determines whether this was a navigation to a specific page, triggered by backToPage().

direction string

Determines how the navigation was triggered, possible values are "to", "back", "backToPage", and "backToTop".

getBackgroundColor

Gets current value of property backgroundColor.

Determines the background color of the SplitContainer. If set, this color overrides the default one, which is defined by the theme (should only be used when really required). Any configured background image will be placed above this colored background, but any theme adaptation in the Theme Designer will override this setting. Use the backgroundRepeat property to define whether this image should be stretched to cover the complete SplitContainer or whether it should be tiled.

getBackgroundImage

Gets current value of property backgroundImage.

Sets the background image of the SplitContainer. When set, this image overrides the default background defined by the theme (should only be used when really required). This background image will be placed above any color set for the background, but any theme adaptation in the Theme Designer will override this image setting. Use the backgroundRepeat property to define whether this image should be stretched to cover the complete SplitContainer or whether it should be tiled.

getBackgroundOpacity

Gets current value of property backgroundOpacity.

Defines the opacity of the background image - between 0 (fully transparent) and 1 (fully opaque). This can be used to improve the content visibility by making the background image partly transparent.

Default value is 1.

getBackgroundRepeat

Gets current value of property backgroundRepeat.

Defines whether the background image (if configured) is proportionally stretched to cover the whole SplitContainer (false) or whether it should be tiled (true).

Default value is false.

getCurrentDetailPage

Returns the current displayed detail page.

getCurrentMasterPage

Returns the current displayed master page.

getCurrentPage

Returns the currently displayed page either in master area or in detail area. When the parameter is set to true, the current page in master area is returned, otherwise, the current page in detail area is returned.

This method is provided mainly for API consistency between sap.m.SplitContainer and sap.m.App, so that the same code line can be reused.

Param Type DefaultValue Description
bMaster boolean

States if this function returns the current page in master area. If it's set to false, the current page in detail area will be returned.

getDefaultTransitionNameDetail

Gets current value of property defaultTransitionNameDetail.

Determines the type of the transition/animation to apply when to() is called without defining the transition to use. The default is "slide", other options are "fade", "show", and the names of any registered custom transitions.

Default value is "slide".

getDefaultTransitionNameMaster

Gets current value of property defaultTransitionNameMaster.

Determines the type of the transition/animation to apply when to() is called, without defining the transition to use. The default is "slide", other options are "fade", "show", and the names of any registered custom transitions.

Default value is "slide".

getDetailPage

Returns the page with the given ID in detail area. If there's no page that has the given ID, null is returned.

Param Type DefaultValue Description
sId string

The ID of the page that needs to be fetched.

getDetailPages

Gets content of aggregation detailPages.

Determines the content entities, between which the SplitContainer navigates in detail area. These can be of type sap.m.Page, sap.ui.core.mvc.View, sap.m.Carousel or any other control with fullscreen/page semantics. These aggregated controls receive navigation events like BeforeShow, they are documented in the pseudo interface sap.m.NavContainerChild.

getInitialDetail

ID of the element which is the current target of the association initialDetail, or null.

getInitialMaster

ID of the element which is the current target of the association initialMaster, or null.

getMasterButtonText

Gets current value of property masterButtonText.

Determines the text displayed in master button, which has a default value "Navigation". This text is only displayed in iOS platform and the icon from the current page in detail area is displayed in the master button for the other platforms. The master button is shown/hidden depending on the orientation of the device and whether the master area is opened or not. SplitContainer manages the show/hide of the master button by itself only when the pages added to the detail area are sap.m.Page with built-in header or sap.m.Page with built-in header, which is wrapped by one or several sap.ui.core.mvc.View. Otherwise, the show/hide of master button needs to be managed by the application.

getMasterButtonTooltip

Gets current value of property masterButtonTooltip.

Specifies the tooltip of the master button. If the tooltip is not specified, the title of the page, which is displayed is the master part, is set as tooltip to the master button.

getMasterPage

Returns the page with the given ID in master area (if there's no page that has the given ID, null is returned).

Param Type DefaultValue Description
sId string

The ID of the page that needs to be fetched

getMasterPages

Gets content of aggregation masterPages.

Determines the content entities, between which the SplitContainer navigates in master area. These can be of type sap.m.Page, sap.ui.core.mvc.View, sap.m.Carousel or any other control with fullscreen/page semantics. These aggregated controls receive navigation events like BeforeShow, they are documented in the pseudo interface sap.m.NavContainerChild.

sap.m.SplitContainer.getMetadata

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

getMode

Gets current value of property mode.

Defines whether the master page will always be displayed (in portrait and landscape mode - StretchCompressMode), or if it should be hidden when in portrait mode (ShowHideMode). Default is ShowHideMode. Other possible values are Hide (Master is always hidden) and Popover (master is displayed in popover).

Default value is ShowHideMode.

getPage

Returns the page with the given ID from either master area, or detail area depending on the master parameter (if there's no page that has the given ID, null is returned).

Param Type DefaultValue Description
sId string

The ID of the page that needs to be fetched

bMaster boolean

If the page with given ID should be fetched from the master area. If it's set to false, the page will be fetched from detail area.

getPreviousPage

Returns the previous page (the page, from which the user drilled down to the current page with to()). Note: this is not the page, which the user has seen before, but the page which is the target of the next back() navigation. If there is no previous page, "undefined" is returned.

Param Type DefaultValue Description
bMaster boolean

States if this function returns the previous page in master area. If it's set to false, the previous page in detail area will be returned.

hideMaster

Used to hide the master page when in ShowHideMode and the device is in portrait mode.

hidePlaceholder

Hides the placeholder on the corresponding column for the provided aggregation name.

Param Type DefaultValue Description
mSettings object

Object containing the aggregation name

aggregation string

The aggregation name to decide on which column/container the placeholder should be hidden

indexOfDetailPage

Checks for the provided sap.ui.core.Control in the aggregation detailPages. and returns its index if found or -1 otherwise.

Param Type DefaultValue Description
oDetailPage sap.ui.core.Control

The detailPage whose index is looked for

indexOfMasterPage

Checks for the provided sap.ui.core.Control in the aggregation masterPages. and returns its index if found or -1 otherwise.

Param Type DefaultValue Description
oMasterPage sap.ui.core.Control

The masterPage whose index is looked for

insertDetailPage

Inserts a detailPage into the aggregation detailPages.

Param Type DefaultValue Description
oDetailPage sap.ui.core.Control

The detailPage to insert; if empty, nothing is inserted

iIndex int

The 0-based index the detailPage should be inserted at; for a negative value of iIndex, the detailPage is inserted at position 0; for a value greater than the current size of the aggregation, the detailPage is inserted at the last position

insertMasterPage

Inserts a masterPage into the aggregation masterPages.

Param Type DefaultValue Description
oMasterPage sap.ui.core.Control

The masterPage to insert; if empty, nothing is inserted

iIndex int

The 0-based index the masterPage should be inserted at; for a negative value of iIndex, the masterPage is inserted at position 0; for a value greater than the current size of the aggregation, the masterPage is inserted at the last position

insertPreviousPage

Inserts the page/control with the specified ID into the navigation history stack of the NavContainer.

This can be used for deep-linking when the user directly reached a drilldown detail page using a bookmark and then wants to navigate up in the drilldown hierarchy. Normally, such a back navigation would not be possible as there is no previous page in the SplitContainer's history stack.

Param Type DefaultValue Description
sPageId string

The ID of the control/page/screen, which is inserted into the history stack. The respective control must be aggregated by the SplitContainer, otherwise this will cause an error.

transitionName string slide

The type of the transition/animation which would have been used to navigate from the (inserted) previous page to the current page. When navigating back, the inverse animation will be applied. Options are "slide" (horizontal movement from the right), "baseSlide", "fade", "flip", and "show" and the names of any registered custom transitions.

oData object

This optional object can carry any payload data which would have been given to the inserted previous page if the user would have done a normal forward navigation to it.

isMasterShown

Returns whether master area is currently displayed on the screen. In desktop browser or tablet, this method returns true when master area is displayed on the screen, regardless if in portrait or landscape mode. On mobile phone devices, this method returns true when the currently displayed page is from the pages, which are added to the master area, otherwise, it returns false.

needPlaceholder

Checks whether a placeholder is needed by comparing the currently displayed page with the page object that is going to be displayed. If they are the same, no placeholder needs to be shown.

Param Type DefaultValue Description
sAggregationName string

The aggregation name for the corresponding column

oObject sap.ui.core.Control

The page object to be displayed

removeAllDetailPages

Removes all the controls from the aggregation detailPages.

Additionally, it unregisters them from the hosting UIArea.

removeAllMasterPages

Removes all the controls from the aggregation masterPages.

Additionally, it unregisters them from the hosting UIArea.

removeDetailPage

Removes a detailPage from the aggregation detailPages.

Param Type DefaultValue Description
vDetailPage int string sap.ui.core.Control

The detailPage to remove or its index or id

removeMasterPage

Removes a masterPage from the aggregation masterPages.

Param Type DefaultValue Description
vMasterPage int string sap.ui.core.Control

The masterPage to remove or its index or id

setBackgroundColor

Sets a new value for property backgroundColor.

Determines the background color of the SplitContainer. If set, this color overrides the default one, which is defined by the theme (should only be used when really required). Any configured background image will be placed above this colored background, but any theme adaptation in the Theme Designer will override this setting. Use the backgroundRepeat property to define whether this image should be stretched to cover the complete SplitContainer or whether it should be tiled.

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

Param Type DefaultValue Description
sBackgroundColor string

New value for property backgroundColor

setBackgroundImage

Sets a new value for property backgroundImage.

Sets the background image of the SplitContainer. When set, this image overrides the default background defined by the theme (should only be used when really required). This background image will be placed above any color set for the background, but any theme adaptation in the Theme Designer will override this image setting. Use the backgroundRepeat property to define whether this image should be stretched to cover the complete SplitContainer or whether it should be tiled.

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

Param Type DefaultValue Description
sBackgroundImage sap.ui.core.URI

New value for property backgroundImage

setBackgroundOpacity

Sets a new value for property backgroundOpacity.

Defines the opacity of the background image - between 0 (fully transparent) and 1 (fully opaque). This can be used to improve the content visibility by making the background image partly transparent.

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

Default value is 1.

Param Type DefaultValue Description
fBackgroundOpacity float 1

New value for property backgroundOpacity

setBackgroundRepeat

Sets a new value for property backgroundRepeat.

Defines whether the background image (if configured) is proportionally stretched to cover the whole SplitContainer (false) or whether it should be tiled (true).

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
bBackgroundRepeat boolean false

New value for property backgroundRepeat

setDefaultTransitionNameDetail

Sets a new value for property defaultTransitionNameDetail.

Determines the type of the transition/animation to apply when to() is called without defining the transition to use. The default is "slide", other options are "fade", "show", and the names of any registered custom transitions.

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

Default value is "slide".

Param Type DefaultValue Description
sDefaultTransitionNameDetail string "slide"

New value for property defaultTransitionNameDetail

setDefaultTransitionNameMaster

Sets a new value for property defaultTransitionNameMaster.

Determines the type of the transition/animation to apply when to() is called, without defining the transition to use. The default is "slide", other options are "fade", "show", and the names of any registered custom transitions.

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

Default value is "slide".

Param Type DefaultValue Description
sDefaultTransitionNameMaster string "slide"

New value for property defaultTransitionNameMaster

setInitialDetail

Sets the associated initialDetail.

Param Type DefaultValue Description
oInitialDetail sap.ui.core.ID sap.ui.core.Control

ID of an element which becomes the new target of this initialDetail association; alternatively, an element instance may be given

setInitialMaster

Sets the associated initialMaster.

Param Type DefaultValue Description
oInitialMaster sap.ui.core.ID sap.ui.core.Control

ID of an element which becomes the new target of this initialMaster association; alternatively, an element instance may be given

setMasterButtonText

Sets a new value for property masterButtonText.

Determines the text displayed in master button, which has a default value "Navigation". This text is only displayed in iOS platform and the icon from the current page in detail area is displayed in the master button for the other platforms. The master button is shown/hidden depending on the orientation of the device and whether the master area is opened or not. SplitContainer manages the show/hide of the master button by itself only when the pages added to the detail area are sap.m.Page with built-in header or sap.m.Page with built-in header, which is wrapped by one or several sap.ui.core.mvc.View. Otherwise, the show/hide of master button needs to be managed by the application.

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

Param Type DefaultValue Description
sMasterButtonText string

New value for property masterButtonText

setMasterButtonTooltip

Sets a new value for property masterButtonTooltip.

Specifies the tooltip of the master button. If the tooltip is not specified, the title of the page, which is displayed is the master part, is set as tooltip to the master button.

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

Param Type DefaultValue Description
sMasterButtonTooltip string

New value for property masterButtonTooltip

setMode

Sets a new value for property mode.

Defines whether the master page will always be displayed (in portrait and landscape mode - StretchCompressMode), or if it should be hidden when in portrait mode (ShowHideMode). Default is ShowHideMode. Other possible values are Hide (Master is always hidden) and Popover (master is displayed in popover).

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

Default value is ShowHideMode.

Param Type DefaultValue Description
sMode sap.m.SplitAppMode ShowHideMode

New value for property mode

showMaster

Used to make the master page visible when in ShowHideMode and the device is in portrait mode.

showPlaceholder

Shows the placeholder on the corresponding column for the provided aggregation name.

Param Type DefaultValue Description
mSettings object

Object containing the aggregation name

aggregation string

The aggregation name to decide on which column/container the placeholder should be shown

to

Navigates to the given page inside the SplitContainer. The navigation is done inside the master area if the page has been added, otherwise, it tries to do the page navigation in the detail area.

Param Type DefaultValue Description
sPageId string

The screen to which we are navigating to. The ID or the control itself can be given.

transitionName string slide

The type of the transition/animation to apply. Options are "slide" (horizontal movement from the right), "baseSlide", "fade", "flip", and "show" and the names of any registered custom transitions.

None of the standard transitions is currently making use of any given transition parameters.

oData object

This optional object can carry any payload data which should be made available to the target page. The BeforeShow event on the target page will contain this data object as data property.

Use case: in scenarios where the entity triggering the navigation can or should not directly initialize the target page, it can fill this object and the target page itself (or a listener on it) can take over the initialization, using the given data.

When the transitionParameters object is used, this "data" object must also be given (either as object or as null) in order to have a proper parameter order.

oTransitionParameters object

This optional object can contain additional information for the transition function, like the DOM element which triggered the transition or the desired transition duration.

For a proper parameter order, the "data" parameter must be given when the transitionParameters parameter is used (it can be given as "null").

NOTE: It depends on the transition function how the object should be structured and which parameters are actually used to influence the transition. The "show", "slide" and "fade" transitions do not use any parameter.

toDetail

Navigates to a given detail page.

Param Type DefaultValue Description
sPageId string
sTransitionName string

The type of the transition/animation to apply. Options are "slide" (horizontal movement from the right), "baseSlide", "fade", "flip", and "show" and the names of any registered custom transitions.

None of the standard transitions is currently making use of any given transition parameters.

oData object

This optional object can carry any payload data which should be made available to the target page. The BeforeShow event on the target page will contain this data object as data property.

Use case: in scenarios where the entity triggering the navigation can or should not directly initialize the target page, it can fill this object and the target page itself (or a listener on it) can take over the initialization, using the given data.

When the transitionParameters object is used, this data object must also be given (either as object or as null) in order to have a proper parameter order.

oTransitionParameter object

This optional object can contain additional information for the transition function, like the DOM element, which triggered the transition or the desired transition duration.

For a proper parameter order, the data parameter must be given when the transitionParameters parameter is used (it can be given as "null").

NOTE: it depends on the transition function how the object should be structured and which parameters are actually used to influence the transition. The "show", "slide" and "fade" transitions do not use any parameter.

toMaster

Navigates to a given master page.

Param Type DefaultValue Description
sPageId string

The screen to which drilldown should happen. The ID or the control itself can be given.

sTransitionName string

The type of the transition/animation to apply. Options are "slide" (horizontal movement from the right), "baseSlide", "fade", "flip", and "show" and the names of any registered custom transitions.

None of the standard transitions is currently making use of any given transition parameters.

oData object

Since version 1.7.1. This optional object can carry any payload data which should be made available to the target page. The BeforeShow event on the target page will contain this data object as data property.

Use case: in scenarios where the entity triggering the navigation can't or shouldn't directly initialize the target page, it can fill this object and the target page itself (or a listener on it) can take over the initialization, using the given data.

When the transitionParameters object is used, this data object must also be given (either as object or as null) in order to have a proper parameter order.

oTransitionParameters object

Since version 1.7.1. This optional object can contain additional information for the transition function, like the DOM element, which triggered the transition or the desired transition duration.

For a proper parameter order, the data parameter must be given when the transitionParameters parameter is used (it can be given as "null").

NOTE: it depends on the transition function how the object should be structured and which parameters are actually used to influence the transition. The "show", "slide" and "fade" transitions do not use any parameter.