Book Review: Flash Development for Android Cookbook

September 22nd, 2011 by Adrian

Flash Development for Android Cookbook front cover

Title: Flash Development for Android Cookbook
Author: Joseph Labrecque
Publisher: Packt Publishing
Released: June 2011
Website link: http://goo.gl/icJsk
Amazon link: http://goo.gl/TGBv5

For any Flash or Flex developer looking to create applications for mobile (in particular Android ones) then this is a great book to have on your desk! Weighing in at 372 pages, there is a lot of content in there just waiting for you to try out and play with.

First things first, this is a Cookbook. It’s not a reference title listing every single API and documenting every single class available. Though to be honest, it seems to cover most of the new AIR for Android features. The idea behind a Cookbook is to provide you with a selection of ‘recipes’ or common tasks, and then explain how to go about solving them in a clear and concise way. This book does this brilliantly. It is the sort of book you can dib into when you have a specific thing to get done in your app and you’re not sure where to start. Having said that, I basically read it from cover to cover, and still found it very informative and enjoyable.

The book is broken up into the following 11 chapters …

  • Chapter 1: Getting Ready to Work with Android: Development Environment and Project Setup (10 recipes)
  • Chapter 2: Interaction Experience: Multitouch, Gestures, and Other Input (13 recipes)
  • Chapter 3: Movement through Space: Accelerometer and Geolocation Sensors (9 recipes)
  • Chapter 4: Visual and Audio Input: Camera and Microphone Access (6 recipes)
  • Chapter 5: Rich Media Presentation: Working with Images, Video, and Audio (7 recipes)
  • Chapter 6: Structural Adaptation: Handling Device Layout and Scaling (12 recipes)
  • Chapter 7: Native Interaction: StageWebView and URI Handlers (10 recipes)
  • Chapter 8: Abundant Access: File System and Local Database (7 recipes)
  • Chapter 9: Manifest Assurance: Security and Android Permissions (6 recipes)
  • Chapter 10: Avoiding Problems: Debugging and Resource Considerations (6 recipes)
  • Chapter 11: Final Considerations: Application Compilation and Distribution (10 recipes)

All these chapter are equally important and cover a wide range of features, but which ones you’ll actually need to use will depend on your project and what you are trying to achieve. Although the title of this book specifies Android, most of the code in this book will work equally well on iOS devices and the BlackBerry PlayBook. That’s the joy of developing using ActionScript and AIR! :-)

I was particularly pleased to see that nearly all the code examples were IDE agnostic and didn’t tie you in to the Flex framework. They concentrated on using pure ActionScript in whatever IDE you feel comfortable working in. In fact, Joseph even went to the trouble of explaining any IDE specific stuff using example in Flash Pro CS5.5, Flash Builder 4.5 and FDT 4.1.

Once you have had a flick through at some of the examples it quickly becomes clear that Adobe have done a really good job at providing a consistent and logical API for achieving all these new mobile specific things. And this book does a great job of demystifying it all.

My one criticism would be that there is quite a lot of repetitive code (about 14 lines) in each example, where Joseph sets up an output textfield (and accompanying textformat) for demonstration purposes. But I guess I noticed it more because I was reading the book straight through (not how it was intended to be read). At least this way, each ‘recipe’ or example is self contained and provides everything you need to get you up and running easily.

I did notice a few errors here and there (code and layout), but nothing too serious that would cause you issues.

I’d thoroughly recommend this title to anyone who is interested in creating mobile apps for either Android, iOS or PlayBook using AIR and ActionScript.

Sample Chaper
Chapter 4 - Visual and Audio Input: Camera and Microphone Access can be downloaded as a free PDF file here.

Related books by other authors and publishers include:

Posted in AIR, Android, Books, Mobile | No Comments »

Link to Android App in Marketplace from a Webpage

December 10th, 2010 by Adrian

Android Marketplace

If you have a mobile version of a website you may want to point users in the direction of an app that is available in the Android Marketplace. If so, you can do it like this …

Get the app here

Note: The HREF link is pointing to …

market://details?id=your.package.name.here

Posted in Android, Mobile | 3 Comments »

AIR 2.5 for Android now available on the Android Marketplace

October 8th, 2010 by Adrian

AIR 2.5 for Android

AIR 2.5 for Android has just been formally released and is now available on the Android Marketplace. Which means end-users can now get the runtime and then install your apps created with AIR. Users will need to be running Android 2.2 (Froyo) to see it in the Marketplace.

Ryan Stewart has a blog post with some info on publishing your apps to the marketplace.

Here are some other useful links to help you get started with AIR for Android …

Luckily my iPhone contract has just expired. Android here I come! :-)

Adobe AIR for Android Install Screen

Posted in AIR, Android, Mobile | No Comments »