Index

Classes

Class

Methods

Class Banana.Controls.Label


Extends Banana.Controls.DataControl.

Methods borrowed from class Banana.Controls.DataControl:
dataSetBind, getData, unDataSetBind, updateDisplay
Methods borrowed from class Banana.UiControl:
addControl, addCss, addCssClass, getAttribute, getAttributes, getClientId, getCss, getCssClass, getDimensions, getHtml, getHtmlAttributes, getState, getStyle, getStyleProperty, hasCssClass, registerEvents, removeAttribute, removeCssClass, removeState, setAttribute, setClientId, setCss, setEnabled, setState, setStyle, setVisible, switchCssClass, triggerEvent, unregisterEvents
Methods borrowed from class Banana.Control:
applyToChildren, bind, clear, createComponents, findControl, generateUniqueId, getControls, getDomEventTypes, getFirstUiControl, getId, getPage, getParent, getProxy, hasBind, invalidateDisplay, onPreInvalidateContents, onWindowResize, remove, render, setId, setPage, setParent, unbind, unload

Defined in: Label.js.

Class Detail
Banana.Controls.Label()

Creates a label. Useful to display text only

Method Detail
{String} getTagName()
Returns:
{String}
{this} setData(data, ignoreEvent, ignoreDom)

overwrite this function to prevent triggering the change event We do this to increase performance. we dont need the change event We also add the data as a control. The reason for this is because the label control will be rendered first without any data inside. then in the update display, data will be inserted. With many controls this insertion will be noticed in the gui rendering. To prevent this we make sure that the control will always render at once with data already inside

Parameters:
{mixed} data
for the label
{boolean} ignoreEvent
when true no datachanged is triggered. This is useful when you are running in a circle or performance issues
{boolean} ignoreDom
when true setDomData function is not called. Useful in cases of optimizing performance
Returns:
{this}
setForControl(control)

Sets the control which belongs to the label. The result is that you can click on the label to focus the control

Parameters:
{Banana.Control} control
{this} setTagName(tag)

Sets tag name of the label. use this if you want to overwrite the default label tag. for example. when you want to render images inside the label

Parameters:
{String} tag
Returns:
{this}

Documentation generated by JsDoc Toolkit 2.4.0 on Wed Dec 05 2012 22:01:53 GMT+0100 (CET)