Actionscript Flash flex

How to get smooth image scaling in Flex

Great article from Ben Longoria about how to get smooth image scaling in Flex.

Actionscript Adobe Air Flash flex

Remove Adobe Air Status Bar (in Flex Builder) [Update]

This is something so simple but it took me hours to figure it out (actually I do not know why): I wanted to remove the status bar from my Adobe Air application window. I use Flex Builder to develop my Air application.

I wanted to remove the status bar in the bottom of the window because it is useless and it looks bad in fullscreen mode.

As standard MXML element Flex Builder uses the mx:WindowedApplication. You just have to add a simple
and you get rid of that stupid status bar.

[Update 8. April 2009]
just causes the status bar to not being displayed. However, it is still there but not visible.

Thus, I added
in the title tag of WindowedApplication and implemented removeStatusBar(event) as following:

private function removeStatusBar(event:AIREvent):void{

Actionscript Adobe Air Flash flex

Draw Image Reflection in Adobe Flex

Recently, I needed an image reflection effect in Flex. This would not be complicated to achieve for a Loader image object in Flash Actionscript 3 but the more for Flex as everything needs to be a bit more complicated in Flex when it comes to customizing.

Flex Image Reflection

Actionscript Adobe Air Flash flex

How to Generate Thumbnails with Adobe Air

This article from Kevin Hoyt’s blog has been a hell of a lot useful for me. It describes how thumbnails can be generated on the fly of high-res images with Adobe Air and how they can be saved to HD.

As some code is missing in Kevin’s tutorial, here is the code of two Adobe Air thumbnail generation applications.

Actionscript Adobe Air fh wiesbaden flare Flash flex Hochschule RheinMain Multi-Touch Tangible Interfaces Visualization

Vispol Tangible and Multi-Touch Interface Video

This video presents the results of the Bachelor thesis of Frederic Friess at the Vislab of the Wiesbaden University of Applied Sciences. I have been Frederic’s mentor under the guidance of Prof. Dr. Doerner for this work.

Actionscript Announcement django Flash flex Multi-Touch Portfolio Tangible Interfaces Visualization

Pf Design Media Installation

I helped Sensory Minds to build an interactive multi-touch and tangible media installation for a Werkschau of students from the Hochschule Pforzheim. Graduates are represented by objects that are provided with a fiducial on the underside and a picture of the work on the upper side. As soon as the object is added to the table, pictures of the student’s projects will be loaded and circularly arranged around the object. Those pictures can be browsed via multi-touch. If a user taps on a project picture all pictures to this project will be loaded and will be arranged on a second circle around the project images.

Actionscript Adobe Air flare Flash flex Hochschule RheinMain Visualization

Vispol Multi-Touch Video

This video demonstrates the fundamental multi-touch functions of Vispol. The demonstrated functions contain the creation and modification of persons and objects and connections. Additionally, examples for the application of the layout functions in Vispol are being introduced.

Click here for further information about Vispol.

You can try out the mouse version of Vispol here.

Actionscript flex Uncategorized

Setting the Width and Height of an Object in Flex to 100% with Actionscript

Today I had the problem that i needed to create a Flex element by hand and apply to it a width of 100%.

This goes as easy with MXML as this
<mx:VBox id="wrapperBox"><mx:UIComponent width="100%" height="100%" id="elementXYZ"></mx:VBox>

But you cannot code this to achieve the adding programatically with Actionscript:
var elementXYZ:UIComponent = new UIComponent();
elementXYZ.width = "100%";
elementXYZ.height = "100%";

Instead, you have to use this:
var elementXYZ:UIComponent = new UIComponent();
elementXYZ.percentWidth = 100;
elementXYZ.percentHeight = 100;

Actionscript Adobe Air Flash flex

Calculate and Set Bounds (Bounding Box) from Points in Google Maps Flash [Update]

I’ve got a list of points in my database, which I want to show neatly in a Google Maps Flash Map.

Thus, I …

  1. calculate the bounding box around these points
  2. calculate the center of this bounding box
  3. set the zoom level of the map in a way that the zoomed cutout contains all points
  4. set the center of the map
var bounds:LatLngBounds = new LatLngBounds();
for each(var mapObject in tripMessages){
    var currentLatLon:LatLng = new LatLng(mapObject.latitude, 
var center:LatLng = bounds.getCenter();
Actionscript Adobe Air Flash flex

Figure out if you are using AS3 code in an Adobe Air application

I use my code in both an Adobe Flex and in an Adobe Air application. As I want to use the native menus of Adobe Air I want to prevent that my self-built menu is being added to the Air application. Thus, I need to figure out if the code is running in a Flex or in an Air application. I do this by using the following structure:

var airApp:Boolean = false;
if(NativeApplication.nativeApplication) airApp = true;