This ClickableLabel widget provides a label that, when clicked, fires a labelClicked event with the object reference.
| Inherits from: | oscar.Gui |
| oscar. | This ClickableLabel widget provides a label that, when clicked, fires a labelClicked event with the object reference. |
| Properties | |
| styles | |
| Constants | |
| EVENT_TYPES {Array(String)} Supported application event types. | Register a listener for a particular event with the following syntax: > clickablelabel.events.register(type, obj, listener); |
| Properties | |
| events {<OpenLayers. | all events on the label. |
| container | Reference to the label container. |
| style | block or inline |
| ref Holds a reference to an object. | |
| Constructor | |
| oscar. | |
| Functions | |
| setLabelText | Sets the label text and triggers the labelTextChanged event. |
| appendTo | Appends the the container to the element provided. |
| toggle | Returns true or false if the label has been toggled |
| applyClass | Takes a single CSS class or an array of CSS classes and adds them to the container. |
| removeClass | Takes a single CSS class or an array of CSS classes and removes them from the container. |
| reset | Resets the counter to 0 |
| setTooltip | |
| Constants | |
| CLASS_NAME - oscar. |
Register a listener for a particular event with the following syntax: > clickablelabel.events.register(type, obj, listener);
| labelClicked | Triggered when the label is clicked. Passes the object |
| reference to the listeners. labelTextChanged | Triggered when the label text is changed. |
Sets the label text and triggers the labelTextChanged event.
setLabelText : function( labelText )
Appends the the container to the element provided.
appendTo : function( elem )
Returns true or false if the label has been toggled
toggle : function()
Takes a single CSS class or an array of CSS classes and adds them to the container.
applyClass : function( cls )
Takes a single CSS class or an array of CSS classes and removes them from the container.
removeClass : function( cls )
Resets the counter to 0
reset : function()
setTooltip : function( tooltipText )