XMas is coming early this year :-)
I'm opening the dance with the Rebase library, under a GPL license.
What is it?
The rebase library is a small set of ActionScript 3 modular classes that are meant to either patch some (well-known) platform limitations, enhance existing functionalities that are somewhat lacking, provide minimal support for some basic stuff that should be there, or simply add bits meant to ease development in a web environment.
Organization and purpose
Each class is relatively standalone (either doesn't depend at all on the others, either can make use of native flash class instead of using the proposed replacement) - so, the amount of extra code you link to should be minimal.
Rebase doesn't pretend to be an interesting project (actually, it's a rather boring one) - unlike the JSAS library that will be released soon as well - its sole intent is to make AS3 development for the web a lesser pain in the ass :-).
ExternalInterfaceNG
The ExternalInterface class has a pair of shortcomings (the "available" property is not reliable, and debugging with it is rather painful). This is a drop-in replacement for it that has the same signature, plus an additional shortcut method to throw in javascript. It doesn't depend on anything else. That class is massively used by our JSAS library (to be released).
CapabilitiesNG
The Capabilities native class has naming quirks, and miss some informations. If in an applicable context, the CapabilitiesNG class provides these additional informations fetched from javascript land and exposes them to the ActionScript developer. This class depends on ExternalInterface(NG).
ZMError
The ZMError class is a very blunt extension to the native Error class.
Uload
There is no native way (that I'm aware of) to be notified that the web-page inside which your swf is embedded is being left (or closed) by the user. The Uload class patches this (if in an applicable context), and sends an UNLOAD event in ActionScript, onto the dispatcher of your choice. Depends on ExternalInterface(NG).
WackyWheels
Mouse wheel support in AS is a... err... problematic. This class is meant to patch it.
Unlike other existing solutions (http://blog.pixelbreaker.com/flash/as30-mousewheel-on-mac-os-x/ or http://hasseg.org/blog/?p=138) this one doesn't require you to add an extra <script> to your webpage - as it's entirely embedded into your swf. Apart from that, it's possible I'm handling more problematic situations than the others. Depends on ExternalInterface(NG) and CapabilitiesNG.
Mondane classes
The MimeService, HTML4Colors and SVGColors are very simple classes meant to get basic support on these (pretty much self-explanatory).
Logging infrastructure
One of the weakest feature of the flash platform is its logging/tracing ability. Pretty much, you are stuck with "trace", assuming you are able to connect a debugger to the swf. If you are in any situation less cozy than FB on your macbook pro, you are probably stuck tossing a coin.
The idea of the ErrorLogger class is to provide a unique logging class that will redirect its output to whatever backend you have selected (trace, javascript dump, javascript console, inline HTML, or even POSTing on a server, or whatever else logging backend you would develop), letting you obtain informations from non-developers, debug remotely, work in environments not meant for FB (embedded in a xul application, for eg), or simply enjoy something a little more usable than the damn Eclipse console.
Whether or not the logging is on, and what backend it uses is indifferent as far as the rest of your code is concerned.
This depends on ExternalInterface(NG) and ZMError.
Initialize
It's quite common (and desirable) to set application parameters at runtime, after sourcing them from a separate file, possibly retrieved from the network.
The "initialize" class is meant to populate the accessors of a given ActionScript object described in a given interface, using the values found in an XML or JSON object.
The purpose of this is to greatly reduce the amount of code (and gymnastics) you usually do in order to use runtime sourced values.
Pretty much, the only thing you will have to do is Initialize.instance.fromJSON( myObject, someInterface, myJSON ), and have your properties magically set. This is at the core of the BundleService library (to be released).
Documentation, download
The wiki page is here. The HG repository is there.
Let me know if this library is useful to you or if you have problems with it.
1
ljouanneau
Sunday, December 20 2009, 12:21
ljouanneau's status on Sunday, 20-Dec-09 11:21:36 UTC
we released some utilities class for AS3 related to html/browser : http://tinyurl.com/yctuq4c #zoomorama #opensource...