Mike Chambers

code = joy

Archive for the ‘ActionScript’ Category

Serializing File Reference Instances in Adobe AIR

with 8 comments

In one of the projects I am working one with the Adobe AIR bus tour, I had a need to serialize instance of File class to the file system. Normally you can do this with File.writeObject(), but as the player serializer / de-serializer does not know about the File class, this would not work for me.

I came up with a simple solution that I wanted to share. Basically, you need to extend the File class and provide the meta data for it to tell the player how to serialize and de-serialize the class. This will then allow it to be serialized to the file system.

Here is the code:
Read the rest of this entry »

Written by mikechambers

June 22nd, 2007 at 1:39 pm

Posted in ActionScript,air

Open Source Amazon S3 ActionScript Library

with 4 comments

Christian Cantrell has released and open sourced an Amazon S3 ActionScript 3 Library. This can be used to send and retrieve items to an from the Amazon S3 storage service from an Apollo application.

We posted a video of Christian showing of an appliction that uses the API a couple of weeks ago.

You can find more information here.

Written by mikechambers

May 30th, 2007 at 8:46 am

Posted in ActionScript,air

Excluding Classes from being Compiled into SWF

with 9 comments

Did you know that you can exclude ActionScript classes from being compiled into the final SWF? You may want to do this to decrease file size, but still have the classes avaliable for type checking.

You can find out how to exclude classes from being compiled here.

Written by mikechambers

May 25th, 2004 at 6:51 am

Posted in ActionScript

Colin Moock’s Essential ActionScript 2.0 Chapter Online

with 3 comments

We have posted a chapter from Colin Moock’s forthcoming tome on ActionScript 2, titled Essential ActionScript 2.0.

You can read chapter 2, “Object Oriented ActionScript”, here.

You can find more information on Essential ActionScript 2.0 from here.

Written by mikechambers

April 23rd, 2004 at 1:21 pm

Posted in ActionScript

MXNA Sample Application Source Code Released

with 9 comments

Just a quick fyi, we have posted the source code for my MXNA sample application.

You can view the app, read some info, and download the source code from here.

Written by mikechambers

March 29th, 2004 at 4:35 am

Posted in ActionScript

Challenge : Search engine in 4 lines of code?

with 25 comments

I was just reading this article about the closing of WebMonkey. One of the things they mentioned were “stunt journalism” articles where they would do things such as write chat engines, or search engines in four lines of code.

Hmm… pretty interesting. So, knowing the ingenuity of the Flash community, I thought I would see what you could do. So, lets start off with something easy, can you create a search engine in Flash in 4 lines of code or less? If so, post the code in the comments (you can use any components included with Flash MX 2004 Pro).

Written by mikechambers

February 25th, 2004 at 8:32 pm

Posted in ActionScript

Atom ActionScript Class v.22

without comments

Just a quick fyi. I have updated my ActionScript 2 Atom class.

You can find more info on the latest changes, and well as view the class here.

Written by mikechambers

February 12th, 2004 at 5:18 pm

Posted in ActionScript

W3CDateTime ActionScript Class

with 2 comments

As part of the ActionScript 2 Atom class that I am putting together, I have created an ActionScript class that represents a W3CDateTime string. This is the format that Atom uses to represent dates.

A beta of the class and simple usage example is included below. If you have any questions or suggestions (especially parsing optimizations), or find any bugs, please post them in the comments.

Read the rest of this entry »

Written by mikechambers

February 6th, 2004 at 6:53 pm

Posted in ActionScript

Atom Feed ActionScript 2 Class Alpha

with 12 comments

I am putting together an ActionScript 2 class to represent and parse Atom feeds. I have put together an early alpha version of the class, but wanted to get some feedback on it before I continue work on it.

Read the rest of this entry »

Written by mikechambers

February 5th, 2004 at 4:32 pm

Posted in ActionScript

EventProxy.as : Proxying Events

with 23 comments

One of the issues I ran into while building the MXNA WebService example app, was that both the ComboBox and DataGrid both broadcast “change” events. This meant that I could not have a separate function to listen for each event (and have the functions run within the scope of the feedView class).

Read the rest of this entry »

Written by mikechambers

January 28th, 2004 at 2:18 am

Posted in ActionScript