Events

Description

The events section of the Viewbox Properties pane in the Viewbox Builder displays a list of global events.

The global events shown here fall into two categories, the first category being default events. Default events are events like the onDown or onClick events. Local variations of these same events can be defined for individual items inside a viewbox control by using the settings in the 'Items' pane's 'Javascript' section. When no action is defined for a given local event for an item on the items pane, then the global default can be used.

The second category is comprised of events for which there is no local definition and that target the viewbox control itself. These are events like onBeforeDraw, onDraw, and onPopulate. Draw events fire when the viewbox is drawn and populate events fire when the viewbox is populated with data. The onSelectComplete event falls into this category too. The onSelectComplete event is rather unique in that it fires only after all of the onSelect events listed in the items pane have fired..

Name
Description
onBeforeDraw

Fires before a draw anytime the viewbox is going to be redrawn.

onBeforePopulate

The onBeforePopulate event fires before a viewbox is populated.

onBeforeSelect

Defines a default event. If no onBeforeSelect event is defined for an item in the viewbox, then this 'global' onBeforeSelect' event will be used by default.

onBlur

This event fires whenever a viewbox control gets or loses focus.

onChange

This event fires when the value of the viewbox changes.

onClick

This defines a default onClick event that fires whenever an item in the viewbox is clicked on.

onDblClick

This defines a default onDblClick event that fires whenever an item in the viewbox is clicked on twice.

onDown

Defines a default onDown event that fires when the mouse button is pressed down whenever an item in the viewbox is clicked on..

onDownHold

This default event is used when a mouse key is pressed down, and then held in the down position, over an item that has no specific onDownHold event defined

onDraw

Fires whenever the viewbox control is drawn or re-drawn.

onFocus

This is a default event that fires when an item in a viewbox control gets focus.

onInitialize

Fires once the viewbox is set up. This happens after the onDraw and onPopulate events fire.

onPopulate

The onPopulate event fires once the viewbox has been populated with data.

onRightClick

This is the default event that fires when the right mouse button is clicked over an item in a viewbox. The item cannot have a local onRightClick event in its definition if the default onRightClick event is to be used.

onSelect

A default event that fires when an item in a view box is selected, presuming that the item does not already have a local onSelect event definition.

onSelectComplete

If multiple items in the viewbox have onSelect events, then on SelectComplete fires once everything has been selected.

onSwipe

This defines a default onSwipe event that happens when an item is swipped, as on a cell phone.

onUp

This is the default or global onUp event. The onUp event fires when a mouse button is lifted, after an item in a viewbox is clicked on. This is assuming the item in question does not have a localized onUp event as part of the item's definition.

See Also