The FlashChemist!

My Experiments and Thoughts on the Flash Platform

Creating AS 3.0 AIR Projects in Flex Builder 3.0 /Flash Builder 4.0

leave a comment

While this is an ideal choice of making AIR desktop applications for those who does not want the Flex framework, I am still surprised that Adobe didn’t add this option to its new IDE product, Flash Builder 4.0. Flex/Flash Builder being the best AS 3.0 editor so far, this option is really missing.

There is a bug in the Adobe JIRA – https://bugs.adobe.com/jira/browse/FB-9303 . But honestly, this looks like a natural choice for Adobe (!?)

I was using a hack for making this work with Flex Builder 3.0 and same works for Flash Builder 4.0. Its is a simple method though:

In the Flex/Flash Builder IDE, select ‘New >> Project’ and select ‘Flex Project’ option.

From the Wizard, please select ‘Desktop Application (Runs on AIR)’, give a project name and click ‘Next’ button instead of your usual ‘Finish’ button.

The next screen prompts for defining the folder for debug. Leave it as is, unless you want to, and click on ‘Next’ button.

The next screen is where you have to do some magic. Here it is.

Change the file extension of ‘Main Application file’ from .mxml to .as — nothing else.

Now click your favourite ‘Finish’ button, and you are set. But, if you run your project, it doesnt show up; this is because the visibilty option of your native window is set to ‘false’ by default. So, open up your application XML file (That will be in the root and named ProjectName-app.xml), and uncomment the sub node of the node and set it to true. Here is how it will look like:

Now, you have your AS3 AIR project, and you have access to all the AIR API’s, and your ’stage’ attribute will have the AIR related properties.

Workaround, still works nice. Adobe, we need this option from the wizard.

Written by Vipin

June 1st, 2010 at 2:47 pm

Posted in AIR, Flash

Tagged with , , , ,

Kevin Lynch responds to the “Flash vs iPhone/Pad and HTML5″

leave a comment

Here is an interview with Adobe CTO Kevin Lynch at the Web 2.0 expo. Few of his comments goes like this

‘We will try to make the best HTML 5 tool in the world’

‘We don’t want to play technology game when Apple is playing Legal game’  about Apple coming up with SDK Licene 3.3.1

‘With Flash CS5 iPhone exporter, we proved that we can make same application work on multiple platforms, and Apple didn’t like it’

Watch it here.

Written by Vipin

May 7th, 2010 at 7:37 pm

Posted in Flash, web

Tagged with , ,

Flash Player 10.1 Multi Touch demo

leave a comment

See this awesome demo of a multi touch social media visualization for Pespsico, done with Flash Player 10.1’s new multi touch capabilities.

Written by Vipin

May 5th, 2010 at 8:54 am

Posted in Flash

Tagged with , ,

JSLint – The JavaScript Code Quality Tool

leave a comment

Again, accidently saw this cool online tool called JSLint – A Javascript Code quality tool. In their own words ‘JavaScript program that looks for problems in JavaScript programs’  JSLint takes a javascript code, analyze it and reports the problems in it.

JSLint does not follow the ECMAScript standards, rather it follows a professional and stricter subset of it, which can be found in Code Conventions for the JavaScript Programming Language.

More details about the standards can be found here and here is the link to JSLint. Test your JS code today!

Written by Vipin

March 3rd, 2010 at 6:43 pm

Posted in web

Tagged with ,

PDFObject – Embed PDF files in web pages

leave a comment

Just saw a Javascript utility called PDFObject to embed PDF files in HTML pages. It works same as SWFObject which is used to embed flash movies in HTML documents.

Here is the link to the site.

Written by Vipin

March 3rd, 2010 at 6:40 pm

Posted in web

Tagged with ,

Flash Player 10.1 on Google’s Nexus One Phone

one comment

Written by Vipin

March 3rd, 2010 at 6:38 pm

Posted in Flash

Tagged with , ,

A PureMVC multicore sample for pure AS3 Flex Builder 3.0 project

leave a comment

I have been searching for a sample of pure as3 project sample (using Flex Builder 3.0), for a new assignment. I have been using PureMVC multicore for my module Flex/AIR based applications, but never did a pure as3 project.

Here is the link to the beautiful tutorial by Actionscript 3.0 design patters. The source is available for view or download. The downloaded file is a Flex Builder archive and can directly be imported into Flex Builder workspace.

Written by Vipin

March 3rd, 2010 at 6:33 pm

Posted in Flash

Tagged with ,

HashTab – Free Hash Checking Utility for Windows and Mac

leave a comment

Here is a cool utility that bakes into your OS file explorer. The utility is an OS extension and once installed you can (on windows) right click on a file and select ‘Properties’, which gives you an additional tab called ‘File Hashes’, which has different hashes of the file. On Mac select “File Hashes” (on 10.5 the “File Hashes” menu item will be found under the “More” submenu). HashTab supports many hash algorithms such as MD5, SHA1, SHA2, RipeMD, HAVAL and Whirlpool. Hashtab is supported as a Windows shell extension and a Mac Finder plugin.

Hash values are used to check the file integrity when you transfer files over a protocol, or after zipping and unzipping the same.

Download the utility here.

Written by Vipin

March 3rd, 2010 at 6:12 pm

Posted in Utilities

Tagged with ,

Get AIR 2.0 SDK Work on Your Flex Builder 3.0

3 comments

I have been trying to get AIR 2.0 beta work on my Flex Builder 3.0 on Windows (I am using XP, but it should be more or less same on all Win boxes). I didnt find any straight forward tutorial from anyone which takes us the step-by-step way :)

I did make it work, so here is how:

Its obvious that you will have Flex Builder 3.0 installed on your machine. I am using Flex Builder 3.0 plug-in on Eclipse Ganymede.

Download the AIR 2.0 beta SDK from Adobe Labs. Its a zip file which is intended to ovelay your current SDK, that means its a collection of files which are going to replace your current files in the SDK folder.

Next, make a copy of your latest SDK. I am using 3.4.0, so I made a copy of that folder and named it ‘3.4.0.air.2.0beta’. Hope you know where will be the SDK placed. For me it was under ‘C:\Program Files\Adobe\Flex Builder 3 Plug-in\sdks’. It may vary for you.

Copy the downloaded zip file inside this SDK folder you created new (3.4.0.air.2.0beta). Right click and say unzip/unarchive/extract all or whatever the utility you are using is saying.

Here, you need to make sure that you are not extracting the zip to a new folder. You should extract the contents of the zip to the root of the folder ‘3.4.0.air.2.0beta’. Make sure you mention to overwrite the files while unzipping. It basically gets you new airglobal.swc and other supporting files (like adl).

Now go back to your project explorer, and create new AIR project.

Right click on the project and select ‘Properties’ and move to ‘Flex Compiler’ tab (shown below)

Click on the ‘Configure Flex SDK’ link. It will open the Flex SDK configuration window (shown below)

Click on Add and add your new SDK you created now (for me the folder ‘3.4.0.air.2.0beta’ and I named it 3.4.0 AIR2). Click OK.

Come back to the project properties window, and select the new SDK from the list (as shown below). You need to select the ‘Use specific SDK radio button, and select the new SDK from the list.

Now you have your AIR 2.0 beta SDK set-up. But this is not it, you have to do one more thing. Open up your application XML file (it should be named ‘YourProjectName-app.xml’. You have to change namespace to 2.0beta if its not set already. The top part of the file will look like below:

http://ns.adobe.com/air/application/1.5.3 will become http://ns.adobe.com/air/application/2.0beta

Now, you should have access to all of your AIR 2.0 api’s. If you are using OS specific API’s like NativeProcess, File.openWithDefaultApplication() methods, you need to add one more tag to your application XML. Please see the tag in the above picture.

Now, hopefully you have everything working with new SDK.

If you are a MAC user, follow this post which tells you how to do it on a MAC OSX.

Hope it helps someone. Happy beta testing… Let me…no no Let Adobe know if you have any issues with the new SDK ;)

Written by Vipin

March 3rd, 2010 at 4:32 pm

Posted in AIR

Tagged with

New Print Features in Adobe AIR 2.0 beta 2

leave a comment

Here is a video interview by Ryan Stewart with Rick Rocheleau on the new features available in Adobe AIR 2.0 beta 2. The new beta is now available in adobe labs.

Thanks Peter Elst for sharing this video on his blog.

Written by Vipin

February 28th, 2010 at 6:31 am

Posted in AIR

Tagged with