Methods of the Renderer API that adds an area under the shell header area that can be used as a message area or for adding additional buttons to the header.
addSubHeader(controlType, oControlProperties, bIsVisible, bCurrentState, aStates)
This method is part of the SAPUI5 sap.ushell.renderers.fiori2.renderer namespace. For more information, see SAPUI5 Demo Kit: Controls .
Parameter | Type | Description |
---|---|---|
controlType | String | The class name of the control type to create. |
oControlProperties | Object | The properties that will be passed to the created control. |
bIsVisible | Boolean |
Specifies whether the sub header control is displayed after being created. If true, The control is displayed according to the bCurrentState and aStates parameters. If false, the control is created but not displayed. |
bCurrentState | Boolean | If true, the created control is added to the
current rendered shell state. When the user navigates to a different
state, or to a different application, then the control is
removed. If false, the control is added to the LaunchpadState. |
aStates |
String |
Valid only if bCurrentState is set to false A list of the launchpad states in which to add the control. |
<SCRIPT language ="JavaScript"> var oRenderer = sap.ushell.Container.getRenderer("fiori2"); oRenderer.addSubHeader("sap.m.Bar", {id: "testBar"}, true, true); <SCRIPT>