Skip to content

Class: ToolbarProxy

ToolbarProxy is a developer-facing class that provides access to a toolbar control for application specific customizations.

Hierarchy

Implements

Summary

Constructors

Properties

Class Properties

Currently none in this class.

Inherited Properties

Accessors

Class Accessors

Currently none in this class.

Inherited Accessors

Methods

Class Methods

Inherited Methods

Constructors

Constructor

+ new ToolbarProxy(context: IContext): ToolbarProxy

Overrides ControlProxy.constructor

Parameters:

Name Type
context IContext

Returns: ToolbarProxy

Methods

getToolbarControls

▸ getToolbarControls(): ToolBarItem[]

This method returns the NativeScript objects of Toolbar Items for this container

Implementation of IToolbarProxy.getToolbarControls

Returns: ToolBarItem[]

The toolbar items objects for this container


getToolbarItem

▸ getToolbarItem(itemName: string): IToolbarItemProxy

Implementation of IToolbarProxy.getToolbarItem

Parameters:

Name Type Description
itemName string takes in _Name property of the toolbar item

Returns: IToolbarItemProxy

returns the ToolbarItemProxy instance of the item by the name


getToolbarItems

▸ getToolbarItems(): IToolbarItemProxy[]

This method returns the top-level controls of Toolbar Items for this container

Implementation of IToolbarProxy.getToolbarItems

Returns: IToolbarItemProxy[]

The toolbar items controls for this container


getVisible

▸ getVisible(): boolean

Implementation of IToolbarProxy.getVisible

Returns: boolean

true/false


isContainer

▸ isContainer(): boolean

Determine if the toolbar control is a container.

Implementation of IToolbarProxy.isContainer Overrides ControlProxy.isContainer

Returns: boolean

true/false.


setVisible

▸ setVisible(value: boolean, redraw?: boolean = true): ToolbarProxy

Sets the toolbar's visible state with / without redraw

Implementation of IToolbarProxy.setVisible Overrides ControlProxy.setVisible

Parameters:

Name Type Description
value boolean visible state
redraw? boolean = true true if redraw after setting the visible state

Returns: ToolbarProxy