Let me preface this post with:
The synchronizing of ActionScript 2 Flash files in Adobe Connect 8 is completely unsupported. It’s recommend you use the Flex 3.5 SDK to build custom pods. This article is meant to show you a
way hack you can use to make your AS2 content sync in an Adobe Connect 8 meeting room. For more information on building a “real” custom pod, download the Collaboration Builder SDK from the Adobe Connect Developer Center. Stay tuned for a video about building custom pods shortly.
Now for the hack
Again, it’s HIGHLY recommended you upgrade your custom pods to ActionScript 3.0. If you want to synchronize content with an AS2 custom pod, you need to load it into a Flex Application. Let’s understand how this works.
A “custom pod” in Connect 8 is nothing more than a Flex Application (currently 3.5 SDK is only supported). When a custom pod is loaded into the Share Pod in a meeting room, every users gets a copy of the pod. You keep the pods synchronized using the SyncConnector component in the Collaboration Builder SDK. For example, if one person drags an image, you send all the other pods a message where to move their image.
In the case of ActionScript 2, the Flex application will communicate with the AS2 file using LocalConnection. It’s something that allows two SWF files to communicate with each other. Sync message are still handled with Flex. The only difference is when Flex receives a sync message it will use LocalConnection to update it’s AS2 SWF:
You can download the example files here. These files should be added to a new Flex project. Check out the Collaboration Builder SDK (mentioned above) for more information on starting a new project.
- ConnectionEmulator.swc/SyncConnector.swc – These are libraries from the Collaboration Builder SDK.
- ServiceEmulatorApp.swf -This is a SWF file to simulate a Connect Meeting room (for testing)
- AS2File.fla/AS2File.swf – This is the SWFile I’ m controlling with the custom pod and the source FLA.
- com.gskinner.utils folder – This folder contains source code libraries for the AS2-to-AS3 communication. Thanks to Grant Skinner for making a couple nice classes!
- ConnectAS2Bridge.mxml – Source Flex Application (3.5 sdk)
Download the source code and check out the comments in the code for a overview of how the code is functioning. Again, don’t be surprised if the syncing is a little flaky. You’re much better off upgrading to AS3.
UPDATE (This is mentioned in the Connect 8 SDK documentation, but I thought I should add it here too)
After you’ve built/tested your custom pod with the ServiceEmulatorApp, you need to comment out the ConnectionEmulator component in your Flex application. Then export a release build. The only two files you need are the ConnectAS2Bridge.swf and the as2file.swf. Rename ConnectAS2Bridge.swf to index.swf, zip up the two SWF files and add them into a Share Pod in Connect