Thursday, October 11, 2007

Adobe MAX 2007 conference: visitor notes

I have to admit that these four thousand people at the conference in majority were very enthusiastic, showed a lot of interest and eager to learn and to be at the top of the technological edge. Adobe gathered a lot of companies and individuals who combined various production line ideas and tricks in attempt to create something new. And many of them succeed. No doubt there was what to see and what to do.
My prime interest was Flex and ActionScript 3.0. Accordingly I attended sessions related to these technologies. Here at glance some thoughts and ideas which caught my attention during sessions:

In Customizing the Flex Framework session:
Skinning, effects, data descriptors, collections, validators, formatters can be extended to implement our own components.
Speaker pointed the use of tag which adds a new scope of content, and if we want to access outer scope from our component, we use 'outerDocument'.
In case of bug in Flex framework impossible to find a workaround for we can "patch the framework". And here we have several options:
Option 1. Extend control as a custom component.
Option 2. Copy class to separate package.
Option 3. Edit mx.* class directly.
A mxml file, which is a main project file format in Flex, is compiled into ActionScript class. And any swf file can be “decompiled” (at least names of classes and methods can be retrieved) relatively easily, because each swf file includes ActionScript binary code (abc) within.

Concerning Best Practices for Developing with ActionScript 3.0 Flex team highly suggests use interfaces and design patterns. First patterns to consider might be Singleton and Observer patterns (from Design Patterns in ActionScript 3.0 session), and Model View controller pattern which "addresses richness of the user interface challenges to help create more flexible applications".
More recommendations include:

Follow name conventions: packagename|ClassName|varName|CONST_NAME;
Stay AWAY from global scope;
Make sure to set optimize compiler to true: (mxmlc -optimize=true);
Do not use generic objects like ClassObject;
Cast array element to particular type;
Don't use uint in loop. Use int for (var i:int=0; iUse runtime share libraries (RSL) and modules

During Flash Player Cross-Domain Security session we discussed security rules and practices. Four rules to take care of security are:
Rule 1. Give least permissions.
Rule 2. Validate input.
Rule 3. Deploy HTTPS consistently.
Rule 4. Prototype early.
Speaker also suggested do not use mix https and http protocols.

For internationalization support in application during Building Global Flex Applications session the audience was introduced to ResourceManager class, resource bundle compiler option, property files, and two ways of including locale content: either embed into one swf or keep all resources separate.

What Makes an interface Feel Intuitive session was about gap between user’s Current knowledge and Target knowledge. This gap - where design is; this is what we care about.
Intuitive means personal. To user.

During Optimizing Aptionscript 3.0 Performance we were suggested
remove listeners when we've done;
put debug code into metatags, and during compiling trip them out;
remove loops by myArray.length (change length to variable);
use != null && is Array instead of try-catch;
use bitwise operators.

We talked about styles on Building Stunning Flex Applications with Flex builder and Creative Suite 3 session. Most amazing was publishing Flash CS3 style template and importing it into Flex using "Flex Skin Design Extensions" for Flex 3 which can be downloaded here: I consider this as an efficient way of graphical skinning. In case of proper names import wizard can recognize Flex objects and create ActionScript required to assign the skin.

Using Adobe Integrated Runtime (AIR) APIs session explained the ways of saving files with:
1. Save dialog
2. Copy to clipboard
3. Drag-n-drop on desktop (which is 'visual' type of clipboard).
Also differences between synchronous (open -> writeMultiByte -> close) and asynchronous (use of events) file operations.

Integrating Flex with Ajax and the Browser session was about Flex-Ajax Bridge (FABridge) - project from Adobe Labs, which makes ActionScript classes available to JavaScript without any additional coding; presented possibilities providing the whole content of Flex application from external xml during runtime; and a “deep linking” (browser history management) mechanism.

Flex 3 browser Back button support: