Well all love Flex’s data binding feature (despite some of the performance problems you can run into). But its so frustrating the humble TextInput component doesn’t support two-way data binding (like the DataGrid does). There are a number of ways to do it, but they all involve a fair bit of typing.
Today, I stumbled across what seems to be a very elegant solution for achieving two-way data binding using TextInput. Strictly, it isn’t data binding but rather, a clever response to built in events. It still achieves the same result, and probably does it with less memory overhead?
I can’t wait for Flex 4 and the two-way data binding shorthand!
Filed under: general
hey scott, thanks for stopping by. i can tell from your posts that you are facing some of the same challenges as my team. we recently spend a huge amount of energy on an effective lazy loading system in a cairngorm-based app. It definitely introduces all kinds of binding issues since you can never count on your objects being fully loaded, but the result is a very snappy interface. it feels like we’re all blazing the trail at the moment. We do use the UM Extensions that you mention in your post, which is extremely helpful for allowing the view to receive notifications without having to send everything through the model.
Hey Jason, yeah, we’ve never used Lazy Loading to this degree either. As you mention, it does create some headaches for Data Binding but it really does makes sense from a performance point of view (but also just a bandwidth and data view point). We’ve been using view stacks and deferred initialisation, it causes similar problems in that you can’t expect an element will always exist, but it really reduces the memory overhead of an application.