Spy Media Photo Viewer
This player was handed to me as just the interface. I wrote the code to grab an XML stream and display the photos entirely as class files in ActionScript 2.0 using a Model-View-Controller architecture (Approximately anyway).
It was actually quite a technical challenge, in terms of pre-loading images and pausing the slideshow if it was running faster than the images could load.
Here are a couple of examples of my ActionScript 2.0:
// Snap scrubber to check mark
if(this._x < 53){
var val:Number = (this._x - 39) <= (53 - this._x) ? 39 : 53;
} else {
var val:Number = (this._x - 53) <= (66 - this._x) ? 53 : 66;
}
this._x = val;
// Dispatch event for interface to reflect current loaded photo
private function broadcastChange(photo:Object):Void{
trace("App.dispatching <photoChange> ("+photo.title+")");
var eventObj:Object = {target:this,type:"photoChange"};
eventObj.photo = photoAttributes(m_photo);
dispatchEvent(eventObj);
}
Get Around
More Work
Other Places
- Flickr. Home of my photos.
- Artykins. My fiancé’s blog.
- HydeStreetChapel.org. My church.