This is related to compiler changes following a specific request in users
list.
  Changes were made to the compiler to help  cairngorm ServiceLocator work
in mxml.


@aharui :

there was a change that added the following to an mxml subclass of
ServiceLocator in a local test project (GithubCommitsViewer):

this.generateMXMLAttributes
  ([2,
'configuratorService',
false,
[mx.rpc.http.mxml.HTTPService, 2, 'id', true, 'configuratorService',
'resultFormat', true, 'text', 0, 0, null],
'commitsService',
false,
[mx.rpc.http.mxml.HTTPService, 2, 'id', true, 'commitsService',
'resultFormat', true, 'text', 0, 0, null],
0,
0
  ]);

But the ServiceLocator class does not implement the generateMXMLAttributes
method.
So I can manually implement it on the original class (although this seems
not necessary in Flex), like so:

 public function generateMXMLAttributes(descriptor:Array):void{
         MXMLDataInterpreter.generateMXMLProperties(this, descriptor);
      }


But that alone was not enough. I also had to change the original
ServiceLocator class to extend from royale EventDispatcher because it was
not being automatically 'upgraded' by the compiler to EventDispatcher (like
Bindable does for regular actionscript VO classes, for example). Without
this change the  'id' properties being set throw errors when the generated
setter code tries to dispatch 'valueChange'.

So the good news is I can get it to work. But it seems like we have some
more things to address here to get it to automatically 'upgrade' the mxml
definitions similar to Flex.

Reply via email to