Archive

Posts Tagged ‘Programming’

Flex: Callback of a Callback

March 26, 2010 Emil Beli No comments
No Gravatar

Depending on architecture of your Flex application (or application you work on), you might have to use callback functions, or it is mandatory to use them. Of course, you shouldn’t be mixing things inside so service functions should remain in service class, where you call your remote objects. Callback function populates your model and that is it. We shall not get into merit should you use MVC, callback functions etc. but presume that you have to do it this way.
So, this is a typical remote service call: Read more…

Post to Twitter Tweet This Post Post to Reddit Reddit Post to StumbleUpon Stumble This Post

Flex 3 – ProgressBar suddenly stopped working? No problem!

May 20, 2009 Emil Beli No comments
No Gravatar

I had to take some parts of the old project to complete deadline for the new project I was working on. One of the components that I used had a ProgressBar, that worked like a charm.

Before…

I had to load some video clip from the net, and show it’s loading progress in accurate measure of bytes, as well as percents and to have it visually as a progress bar. Well, OK, that is not a problem, since I was picking progressEvent which has bytesLoaded and bytesTotal. Those values were filled correctly and on my surprise, progressBar haven’t been updated as the event was fired.

What the hack? This thing worked.

After extensive investigation, I realized that we have changed flash player from 9.x to 10.x. Now, many of the things work in a different way. ProgressBar component is one of it.  Before, you could omit filling the “mode” property, or you could set ti to manual:  mode=”manual”

Now this doesn’t work. you must fill it, and fill it with proper constant:

mode=”{ProgressBarMode.MANUAL}”

Now, it worked as it was before.

Post to Twitter Tweet This Post Post to Reddit Reddit Post to StumbleUpon Stumble This Post

Twitter links powered by Tweet This v1.6.1, a WordPress plugin for Twitter.