2011-01-09 64 views
3

最近我发现了MATE(用于Flex开发)并且想知道:如何将视图中的属性(实际上是navigatorcontent组件)绑定到类中的另一个属性以便它们保持同步(意味着只要类中的属性更改视图中的属性也会发生更改)。如何使用Flex将View的属性绑定到类的属性MATE

因此,如果我们有一个名为Target.mxml和属性targertProp的视图,我们如何将它与具有属性SourceProp的称为SourceClass的类绑定?

在此先感谢

回答

0
<Injectors target="{Target}"> 
    <PropertyInjector targetKey="targertProp" 
        source="{SourceClass}" 
        sourceKey="SourceProp"/> 
</Injectors> 

当然SourceProp必须是[绑定]

+0

是啊!小说你是对的!这回答了这个问题(我应该制定完全不同的,看看这里http://stackoverflow.com/questions/4644379/reflect-property-change-from-one-view-into-another-view-using-a -class-as-intermed) – 2011-01-10 07:10:03

0

阅读下面

http://vinothbabu.com/2010/03/21/introduction-to-mate-framework/

我的文章你如何使用注射器标签一起玩。它是一个非常简单的例子。如果你正在寻找别的东西,让我来。

+0

你能否看看http://stackoverflow.com/questions/4644379/reflect-property-change-from-one-view-into-another-view-using-a-class -as-中间物? – 2011-01-10 07:13:52

1

供将来使用: 小说已正确回答了问题。

其实它应该已经制定了this way

相关问题