Tuesday, April 15, 2008

Developing an image viewer application with Flex and Cairngorm

Developing an image viewer application with Flex and Cairngorm

Sam Williams

Sam Williams

In this article I will describe the process for developing a Flex/Cairngorm application for viewing images (see Figure 1). The application itself is small. I originally developed this project as a demonstration showcase for potential employers. My goal was to develop an app small enough to talk through at an interview while also demonstrating my understanding of the Flex framework and Cairngorm.

The image viewer application

Figure 1. The image viewer application

The application consists of an image viewer compon ent that toggles its method of display at runtime from displaying the images in a grid to a slideshow presentation. The data for the application is provided in an XML file. In addition to the image source URL data, the XML file also contains a creation date for each of the images. The image viewer application allows the user to sort the images alphabetically or by the date created, resulting in a dynamic re-ordering of the images in either the grid or slideshow mode of display.

Requirements

Flex Builder 3 (contains the free Flex 3 SDK)

Cairngorm

Sample files: