开发者

Reading component parameters and setting defaults

开发者 https://www.devze.com 2022-12-27 04:19 出处:网络
I\'m pulling my hair on this because it should be simple. I\'m trying to create a component and set its default properties.

I'm pulling my hair on this because it should be simple.

I'm trying to create a component and set its default properties.

<CustomComp text="Some text" color2="0x939202" value开发者_运维技巧="4.5" />

But when I initialize it, the parameters still don't register.

I do like this:

[Bindable] private var myColor2:uint = 0x000000;
[Bindable] private var myValue:Number = 10.0;

But it just gives me the default, all the time. What am I doing wrong?


For starters the private vars have different names than the vars in the CustomComp tag.

0

精彩评论

暂无评论...
验证码 换一张
取 消