…however, It’s no surprise to me. I had attended the Microsoft Expressions Session 07 event in San Fransisco a while back, when they were giving out early promotions of their software. In the presentation, they had expressed that Silverlight player, although requiring a separate plug-in, was completely free and equally available as Flash player, which made it equally compelling as an alternative platform to Flash. Of course, anyone who’s worked with front-end technologies for a consulting firm would know that this difference is negligible. The most crucial variable to consider here is not how easy it is to obtain the plug-in, but rather, how many people already have the plug-in installed. I’ve worked with many clients that are afraid of anything that has a market penetration less than 95%, which in itself is frustrating when it requires me to trail behind the latest Flash technology.
Market penetration is the name of the game, and Flash has an 11 year head start.
I had recently came across a situation with a project of mine where concrete referencing resulted in a SWF file that was far more bloated than it clearly should have been. Yet another reason why abstraction is so great — although perhaps it should have been obvious in the first place.
The project in question revolves around an MVC architecture, where multiple distinct view/controller pairs share a common model. The pairs were completely independent from each other with the exception of said model, and each were relatively expensive to instantiate. Because of this, I decided to compile each pair into separate module SWFs that would be loaded into a single wrapper SWF. In addition to loading, the wrapper would also create the model and pass it into all of the modules.
I soon realized the wrapper SWF had become 160KB in size…
Clearly, something was wrong, so I investigated. (more…)
While motion tweens really aren’t my thing, let alone Flash design in general, I was quite intrigued by the vCam AS3 tool by Brian Heisey. The tool was originally released in 2005 by Sham Bhangal and Dave Dixon, and Brian updated it to function in AS3 with a few additional effects as well. Best of all, it’s free.
I recently had a project where I had to run some fancy regex and recursion on strings written as excel-style formulas. It was an enjoyable project, as I don't often have the opportunity to use regex or recursion in Flex. However, one of the steps in the process required me to perform what, I thought, should have been a relatively simple task: Take a string of values and separate them by a comma delimiter.
Under normal circumstances, the solution should be as simple as:
However, this failed to account for nested delimiters. For example, A,B,(C,D) would split into A B (C D), instead of the more desired result of A B (C,D). Standard string manipulation indiscriminately splits regardless of the existence of parenthesis, or any grouping operators for that matter. (more...)
After having a need for creating hot key shortcuts on multiple different occasions, I decided to break down and create a highly-reusable system that integrates seamlessly into any Flex app. I spent some time and planned out several different use-cases that the system will need to account for. A few considerations were as follows:
Don't observe hot keys when typing in a text field.
Group multiple hot keys such that they can be collectively prioritized or enabled/disabled (this is especially crucial for modal popups).
Implement easy-to-use behavior to common components.
Keep references weak.
I'm quite satisfied with the results so far, and feel confident that my system will be adaptable to these use-cases and more. Nonetheless, I'd like to push out a pre-release for other developers to test and play with (and perhaps give me feedback as well).
The formal release for the hot key system will include more thorough documentation and meta-data tags for Flex Builder.
 UPDATE: It's been brought to my attention that the CTRL buttons aren't working for people, and I'm pretty sure it has to do with differences between Mac and PC (it's only working for Mac right now). Apparently keycodes output different values via different OSes, so I'll probably have to switch over to charcode. I'll explore this further...
Here's a technique I learned a few months back that I've been meaning to blog about. I've always been displeased by my client's spam detection, as it was always either of two extremes: ignoring spam or marking legitimate mail as spam. From my experience, Gmail has always provided the most reliable spam filtering, and it was right around this time that I discovered a way to utilize it. The steps involved vary depending on what your mailserver supports, so I've listed two different solutions: (more...)
A friend of mine just introduced me to an interesting approach to image resizing called seam carving. It's a solution to the challenge of preserving both the size and composition of an image, and well....perhaps this video will explain it better than I could.
It also turns out that someone built an RIA that imitates this application, which you can check out for free here: http://rsizr.com/
Rsizr is also planning to release a Flash app that can present any image on your site with the scalability demonstrated in the seam carving presentation (although from my experience, it might not run quite as smoothly).
Hey guys, sorry about the lack of updates and responses for those of you genuinely interested (my spam is starting to get a little out of control). I'll be doing a bit of an overhaul now that I've become self-employed. Well...hopefully, anyway...I've been finding myself even more busy now than when I was working full-time!
Anyway, for some news...
My blog has just been added to the Macromedia XML News Aggregator, which means I'm going to have to start creating actual content for this page again. Yep...aside from that and the self-employed details, that's pretty much it for the news here. Stay tuned for more posts! :]
This one set me back a little while. I was trying to set up fileReference for uploading images, but the Event.SELECT handler just wouldn't catch anything. As it turned out, both select and cancel buttons in the browser dialog were dispatching Event.CANCEL events. A little research revealed to me that this was actually a (rather significant) bug with the new Leopard OS + Flash 9 Player. Basically, if you upgrade your Mac to Leopard, you will not be able to utilize any upload or download feature on a Flash-driven site.
This is a little disconcerting, to say the least, but it has been brought to Adobe's attention and will be resolved by the next player update.
In the meantime, how do us Mac-savvy developers cope with this? Here's my solution:
In this article, I'll be going in-depth on the practice known as code-behind for the Flex environment. This is a very powerful technique that all software architects should be familiar with, as it promotes sophisticated encapsulation techniques to separate the formand function from within a UI element. (more...)