Alternative version of widget editor


Example can be found in demo project?, file BlockImageLinkEditorAlt.mxml

Alternative editor?


Alternative editor have the same interface (using functions setXML и getXML). But they are already defined in FZCanvasEditorTemplate parent component.

How it works&


Instead of setXML и getXML definition, where we serialize/deserialize component properties from XML, there we have FZCanvasEditorTemplate. This component do it instead of us.
We must only define the realtions between components and related XML properties.


We must do it by override initializeRelations function.


Example:

override protected function initializeRelations():void {
  // ...
  registerRelation("glow", chkGlowEff);
  registerRelation("glowInDur", numDurIn);
  registerRelation("glowOutDur", numDurOut);
  // ...
}


This kind of editors identical to classic (BlockImageLinkEditor.mxml), but have a more compact code.


 

Developer guide


Overview

API

Lessons