Creating an Image Marquee Component

The real power behind Flex isn't in the base components... the real power is found in extending them.

So... I was reading through some posts on Flexcoders today and found one from a guy asking how to make an image marquee similar to one he had seen on another site. I thought for a minute and couldn't remember if I had seen one in any of the other libraries out there.

BAM! I'll create one!

I started by assembling my tools; a six pack of Diet Coke w/Lime, a rubber duckie, three nails and some duct tape. I was all ready to start McGyvering a getaway helicopter when I remembered the component...

As I thought about the component, I envisioned the images as if they were part of a little train/chain... and decided to extend the Image component by adding linked-list properties to it. This would allow me to 'pull' or 'push' on one of the images/links and naturally any other image in the chain would follow suit.

The component really isn't anything to write home about... but one thing in particular I would like to say... is that masks are our friends. If you are going to create custom components - touching bases with masks is a good idea.

I'm going to spare you the blah blah... on to the sample! As always, right click for source.

[ source: image marquee ]