MACROMEDIA FLEX-CREATING ADVANCED COMPONENTS Manual de usuario Pagina 43

  • Descarga
  • Añadir a mis manuales
  • Imprimir
  • Pagina
    / 52
  • Tabla de contenidos
  • MARCADORES
  • Valorado. / 5. Basado en revisión del cliente
Vista de pagina 42
Binding directions
Binding directions between the spreadsheet and the component property can be:
Two way between the spreadsheet and component property
One way: spreadsheet to the component property
One way: component property to the spreadsheet
You can also bind sub-elements and sub-properties to the spreadsheet.
Related Topics
Two-direction bindings
Spreadsheet to component bindings
Component to spreadsheet bindings
Sub-element and Sub-property Binding
12.2.1 Two-direction bindings
When you use bindings with two-way direction, the spreadsheet is updated when the property value
changes and the property value is updated when the spreadsheet changes.
Note:
The component property needs to have both getter and setter functions for this to work and they must
be marked as Bindable.
[Bindable]
public function get value():Number
{
...
}
public function set value(val:Number):void
{
...
}
1.
Bind a single value property.
For example:
proxy.bind(propertyName, null, bindingId, BindingDirection.BOTH, InputBindings.SINGLETON, OutputBind
ings.SINGLETON);
2.
Bind an array as a 2D array.
For example:
proxy.bind(propertyName, null, bindingId, BindingDirection.BOTH, InputBindings.ARRAY2D, OutputBindings.AR
RAY2D);
3.
Bind an array as a 1D array.
For example:
proxy.bind(propertyName, null, bindingId, BindingDirection.BOTH, InputBindings.ARRAY, OutputBindings.ARRAY);
2013-05-0643
Appendix B: Custom Property Sheet API Reference
Vista de pagina 42
1 2 ... 38 39 40 41 42 43 44 45 46 47 48 ... 51 52

Comentarios a estos manuales

Sin comentarios