DefaultToolbar()

default toolbar

new DefaultToolbar()

Extends

Methods

_initEvent(eventManager)

init event

Parameters:
Name Type Description
eventManager EventManager

event manager

Inherited From:

addButton(button, indexopt)

add button

Parameters:
Name Type Attributes Description
button Button

button instance

index Number <optional>

location the button will be placed

Inherited From:
Deprecated:
  • Yes

addDivider() → {jQuery}

add divider

Returns:
jQuery -
  • created divider jquery element
Inherited From:
Deprecated:
  • Yes

addItem(item)

add toolbar item

Parameters:
Name Type Description
item ToolbarItem | string | object

toolbar item

Inherited From:

destroy()

destroy instance

Overrides:

disableAllButton()

disable all toolbar button

Inherited From:

enableAllButton()

enable all toolbar button

Inherited From:

getItem(index) → {ToolbarItem}

get toolbar item at given index

Parameters:
Name Type Description
index number

item index

Returns:
ToolbarItem -
  • toolbar item at the index
Inherited From:

getItems() → {Array.<ToolbarItem>}

get toolbar items

Returns:
Array.<ToolbarItem> -
  • toolbar items
Inherited From:

indexOfItem(item) → {number}

get index of given item

Parameters:
Name Type Description
item ToolbarItem

toolbar item

Returns:
number -
  • index of given toolbar item
Inherited From:

insertItem(index, item)

insert toolbar item

Parameters:
Name Type Description
index number

index at given item inserted

item ToolbarItem | string | object

toolbar item

Inherited From:

removeAllItems()

remove all toolbar items

Inherited From:

removeItem(item, destroy) → {ToolbarItem|undefined}

remove an item

Parameters:
Name Type Default Description
item ToolbarItem | number

an toolbar item or index of the item to remove

destroy boolean true

destroy item or not

Returns:
ToolbarItem | undefined -
  • removed item
Inherited From:

setItems(items)

set toolbar items

Parameters:
Name Type Description
items Array.<ToolbarItem>

toolbar items

Inherited From: