On 10/30/16, 2:34 PM, "yishayw" <yishayj...@hotmail.com> wrote:
>Well, changing the className does actually change the DOM class in >runtime, >so it seems a bit arbitrary that that's reflected in DOM while changing >style is not. Right now, I'm using this bug(?) as a way to make run-time >style changes. AFAICT, "className" is not a CSS property. There is no other way to apply it when it is declared that I know of. If there is a better way, I'd be in favor of changing the current code. CSS, on the other hand, can be "declared" via CSS files. There are places in both SWF and JS code that is running CSS-handling code and not relying on the browser. We don't want to run that code unless it is necessary. > >I don't really use binding that much but it's good to know that that's an >option. > >I understand the PAYG thing, but now that I want to pay, how do I do it? You can create a variant of SimpleCSSStyles that watches for a particular property to change and then "do the right thing" with that property. Some properties have to send an event to a layout, others can just update the HTMLElement's styles. >Isn't binding expensive? It can be cheaper than it is in the regular Flex SDK. You are welcome to create some other pay-as-you-go mechanisms for changing styles at runtime. -Alex