开发者

How can I validate on demand a flex 4 component size?

开发者 https://www.devze.com 2023-01-25 04:19 出处:网络
The things are s开发者_如何学Cimple, I have a component and I add some content to it making it change it\'s size, immediately I need it\'s new size, but flex only updates the size in the next frame by

The things are s开发者_如何学Cimple, I have a component and I add some content to it making it change it's size, immediately I need it's new size, but flex only updates the size in the next frame by calling updateDisplayList.......hou can I force it to update the size of the component right away.

Any thoughts? :)


Naturally, I found the answer 1 min after, I was calling validateNow(), BEFORE adding the component to it's container. If I call it after that point, all's fine.

0

精彩评论

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