Class: UpdateToolbar

UpdateToolbar()

Extends

Members

attributeMap

Properties:
Name Type Description
Used Object to set the title node's innerHTML
Inherited From:
Source:

enabled

Properties:
Name Type Description
State Boolean of toolbar
Inherited From:
Source:

size

Properties:
Name Type Description
Current Number number of toolbar items set
Inherited From:
Source:

titleText

Text that is placed into the toolbar titleNode
Inherited From:
Source:

toolTemplate

Properties:
Name Type Description
Simplate Simplate that defines the toolbar item HTML Markup `$` - The toolbar item object `$$` - The toolbar instance
Inherited From:
Source:

widgetTemplate

Properties:
Name Type Description
Simplate Simplate that defines the main HTML Markup of the toolbar `$` - the toolbar instance
Inherited From:
Source:

Methods

clear()

Calls parent clear and removes all toolbar items from DOM.
Inherited From:
Source:

clearToolBusy(id)

Sets busy to false of the toolbar item that matches the passed id
Parameters:
Name Type Description
id String The id of the tool to set as not busy
Inherited From:
Source:

disable()

Adds a disabled style class and sets enabled to false
Inherited From:
Source:

disableTool(id)

Sets enabled to false of the toolbar item that matches the passed id
Parameters:
Name Type Description
id String The id of the tool to disable
Inherited From:
Source:

enable()

Removes the disabled style and sets enabled to true
Inherited From:
Source:

enableTool(id)

Sets enabled to true of the toolbar item that matches the passed id
Parameters:
Name Type Description
id String The id of the tool to enable
Inherited From:
Source:

expandExpression(expression) → {String}

Expands the passed expression if it is a function.
Parameters:
Name Type Description
expression String/Function Returns string directly, if function it is called and the result returned.
Inherited From:
Source:
Returns:
String expression.
Type
String

hide()

Sets the toolbar style to none (hidden)
Inherited From:
Source:

indicateToolBusy(id)

Sets busy to true of the toolbar item that matches the passed id
Parameters:
Name Type Description
id String The id of the tool to indicate busy
Inherited From:
Source:

init()

Called upon application startup.
Inherited From:
Source:

invokeTool(parameters, evt, node)

When a tool is clicked on this function handles matching the node to toolbar item instance and performs the actual action
Parameters:
Name Type Description
parameters Object An object of all the `data-` attributes of the node.
evt Event The event object
node HTMLElement The html element that was clicked.
Inherited From:
Source:

isToolEnabled(id) → {Boolean}

Checks the enabled property of the toolbar item that matches the passed id
Parameters:
Name Type Description
id String The id of the tool
Inherited From:
Source:
Returns:
True if the toolbar item is enabled
Type
Boolean

onTitleClick()

Event handler that fires when the toolbar title is clicked.
Inherited From:
Source:

show()

Sets the toolbar style to block (visibile)
Inherited From:
Source:

showTools(tools)

Calls parent showTools which sets the tool collection. The collection is then looped over and added to DOM, adding the left or right styling
Parameters:
Name Type Description
tools Array.<Object> Array of toolbar item definitions
Inherited From:
Source: