-
Notifications
You must be signed in to change notification settings - Fork 0
ability.Triggerable
Gary Soedarsono edited this page Feb 2, 2015
·
14 revisions
extends: [[ability.Ability
|ability.Ability]]
Provides triggers to abilities supported by the app. Normally you don't need to register this to the app. ability.Abilities should do this for you.
To use this class, add the trigger as an attribute name, and the name of the ability as its value.
Supported triggers:
-
pb-click
: Triggers when the element is clicked. -
pb-dblclick
: Triggers when the element is double clicked.
new ability.Triggerable()
pb-click |
Triggers when the element is clicked. |
pb-dblclick |
Triggers when the element is double clicked. |
name | string |
readonly The name of the ability. This is used as an ID to refer to the registered abilities. |
setDefaultValue(!Element el)
Sets the default value of the given element.
el | !Element
|
The element whose default value should be set. |
attributeChangedCallback(!Element el, String name, String oldValue, String newValue)
Handles attribute change.
el | !Element
|
The element whose attribute was changed. |
name | String |
Name of the attribute that was changed. |
oldValue | String |
Old value of the changed attribute. |
newValue | String |
New value of the changed attribute. |
attachedCallback(!Element el)
Called when the element is attached to the document.
el | !Element
|
The element that was attached. |
detachedCallback(!Element el)
Called when the element is detached from the document.
el | !Element
|
The element that was detached. |