LinkBar was meant to be used with a ViewStack

I had to read the source code for LinkBar and its parent NavBar to understand why my LinkBar wasn’t highlighting the clicked item. Turns out, it’s because I use an ArrayCollection as a dataProvider. According to the documentation and the source code, it is possible to use an IList (such as an ArrayCollection), a String…

Read More

Flex: non-UIComponents in the Display List

There are 2 main ways to add non-UIComponents to a Flex Container. 1. You may add the object to a SWFLoader, which does not require its children to extend UIComponent. 2. You may add the object to Container.rawChildren. You have to be careful with the 2nd one. First of all, know that whatever is contained in Container.rawChildren is not…

Read More

Application Domain and External SWF Loading

Why do we care about application domains? I worked on a project that required me to load and unload SWF files into a bigger application (loading mini-games into a virtual world). Every time I loaded a mini-game, it would never unload when I exited it. That will keep accumulating until the app slows down to…

Read More

AS3 Mystery: null, false, 0, “”, NaN

This week I’ve been running unit tests and couldn’t understand why some of them were failing for no obvious reason. To understand why some expressions evaluated to true when they were supposed to be false. I know that I should be careful with null vs false values, but never could I have imagined that the…

Read More

Flex 3D and Wiimote

I haven’t blogged in a while. Too much work to catch after the conference. I’m having a lot of fun with 3D in Flex lately. I found this really great open source library papervision3d. It’s incredibly easy to use. I got the hello world to run in my existing Flex app in under 5 minutes…

Read More