Hi Hugo, you can use MXRoyale in "Royale only" (i.e: jewel) apps. You must to be careful, but code like RPC classes, validators, and probably BindingUtils can be used. I think while you don't use "visual" things, that should be ok. It maybe would require you to try it, but at least RPC classes are working for many others and I used as well some validators time ago.
El vie., 10 jul. 2020 a las 0:39, Hugo Ferreira (<[email protected]>) escribió: > OK. > I'm using Royale only, so BindingUtils (mx version) is not available in my > case. > I will try to workaround in a different way (for sure I have to write more > code) but yes, BindingUtils is a short way in a single line to do the > things (it will be a missing feature). > > Greg Dove <[email protected]> escreveu no dia quinta, 9/07/2020 à(s) > 23:34: > > > When I originally wrote that, it was not intended to be used directly in > > code, it was intended to support the metadata-driven injected bindings, > > specifically with Crux. It is quite specific for Crux. > > It does need BindableChainInfo instances in that last argument instead of > > strings. Perhaps the code can be adapted to be more useful other than > with > > Crux, but would need some time and effort focused on that. > > Is it not viable to use injection in your case? > > > > Since I worked on that, I did also do some work in the mx.binding inside > > MXRoyale. Maybe the BindingUtils in there is more like what you want? (It > > is closer to the original Flex) > > > > > > > > > > > > On Fri, Jul 10, 2020 at 10:02 AM Hugo Ferreira <[email protected]> > > wrote: > > > > > The following line of code, compiles without any issue: > > > BindingUtils.bindProperty(header, "minimized", content, ["visible"]); > > > > > > However at runtime, I got the following error on Google Chrome Console: > > > Uncaught TypeError: Error #1034: Type Coercion failed: cannot convert > > > visible to org.apache.royale.crux.binding.BindableChainInfo > > > at Function.org.apache.royale.utils.Language.as (Language.js:115) > > > at > Function.org.apache.royale.crux.binding.BindingUtils.bindProperty > > > (BindingUtils.js:73) > > > at > > > > > > > > > pt.solidsoft.gc.view.login.Login.pt.solidsoft.framework.form.Form.addElement > > > (Form.mxml:32) > > > at > > > > > > > > > Function.org.apache.royale.utils.MXMLDataInterpreter.initializeStrandBasedObject > > > (MXMLDataInterpreter.js:241) > > > at > > > Function.org.apache.royale.utils.MXMLDataInterpreter.generateMXMLArray > > > (MXMLDataInterpreter.js:127) > > > at > > > > > > Function.org.apache.royale.utils.MXMLDataInterpreter.generateMXMLInstances > > > (MXMLDataInterpreter.js:271) > > > at > > > > > > > > > pt.solidsoft.gc.view.login.Login.org.apache.royale.jewel.Container.addedToParent > > > (Container.js:76) > > > at > > > org.apache.royale.html.Group.org.apache.royale.core.UIBase.addElement > > > (UIBase.js:405) > > > at > > > > org.apache.royale.html.Group.org.apache.royale.core.GroupBase.addElement > > > (GroupBase.js:165) > > > at > > > > > > > > > Function.org.apache.royale.utils.MXMLDataInterpreter.initializeStrandBasedObject > > > (MXMLDataInterpreter.js:241) > > > > > > An explanation: > > > header is the source instance of a component > > > minimized is the public Bindable property that I'm listening > > > content is the target instance of a component > > > visible is the visibility of the target that I want to depend on the > > > minimized property > > > > > > Is this a bug that I should insert on github issues or I'm doing > > something > > > wrong ? > > > > > > -- Carlos Rovira http://about.me/carlosrovira
