Last week at Flash on the Beach 2009 in Brighton, England, Flash authoring product manager Richard Galvan demonstrated some of the improved integration planned for Flash CS5 and Flash Builder 4 (formerly Flex Builder). Like most of the ActionScript developer community, I've been waiting for better integration of the two tools for years, so I tracked Richard down after his presentation and pulled some additional information out of him. If you use Flash Builder as your main programming IDE, but still use Library symbols from a .fla file for graphics, your compiling and debugging process is going to be significantly more convenient in Flash CS5/Flash Builder 4.
This article covers features in unreleased Adobe products. All information is subject to change.
Richard showed me a new type of project in Flash Builder, known as a "Flash Professional Project." Unlike an ActionScript Project, which uses a class file as its main application file, a Flash Professional Project uses a .fla file as its main application file. Whenever Flash Builder needs to compile a Flash Professional Project, it uses Flash authoring, not mxmlc, to do the job. Debugging sessions can also be linked between the two applications.
The main new workflows enabled via Flash Professional Projects are as follows:
Creating a Flash Professional Project
- Create .fla in Flash authoring.
- From the Properties panel or Publish Settings dialog, select Edit Document Class, then choose Flash Builder as the editor.
- Flash authoring automatically focuses Flash Builder, which launches a wizard to create a new Flash Professional Project. The Flash-authoring .fla file is auto-selected as the main application file.
- If the .fla file does not yet have a document class, Flash Builder creates one. The auto-created class extends MovieClip.
Debugging from Flash Builder
- In Flash Builder, while editing any class file in a Flash Professional Project, choose Debug Project.
- Focus automatically shifts to Flash authoring, which compiles the .swf and runs it in Test Movie mode.
- During debugging, trace statements appear in Flash Builder's output console.
- Flash Builder's debugger (not in Flash authoring's debugger) shows the debugging session.
- When the .swf file that was running in Test Movie mode is closed, focus automatically returns to Flash Builder.
Here are a few additional details about the new Flash authoring/Flash Builder integration:
Like all new features, the upcoming Flash authoring/Flash Builder integration is not without its limitations. For me, the most significant "missing link" in the current implementation is the lack of .fla-file introspection. For example, when editing a class file in a Flash Professional Project, Flash Builder will not list the symbols available in the main .fla file, and will not provide code hints for those symbols. Mr. Galvan acknowledged that introspection seems like a sensible idea for the future.
In my own workflow, the new Flash Professional Project won't help much. In my work, I normally use ActionScript projects or Flex projects, which I use to compile application engines from pure code. I still use Flash authoring to create graphic symbols, but I load those symbols at runtime from an external .swf file. For the sake of author-time type-checking and code hinting, I also add a .swc file to my external library path. Hence, I'd ideally like to be able to tell Flash Builder to first compile a .swc and .swf from a .fla file, then compile my ActionScript or Flex Project, and then launch a debugging session. But the ideal world isn't the point here. The point is that Adobe is treating Flash authoring/Flash Builder integration as a first-class citizen, and that's a Good Thing.
Posted by moock at September 27, 2009 05:59 PM