Learning the Android SDK

This is clearly a home side project so don’t expect much real work information here.   I read a little about the Android SDK and since its free and I can quickly get up and running in Eclipse I decided to mess around with it in my spare time.  I also bought the book, Pro Android 2, which has been an excellent primer and reference so far.  If you want a really good introduction to the Android architecture you must watch the introductory videos, the platform is pretty impressive.  One of the best things I like about the platform is it supports multiple processes and has a focus on HTML 5 and HTML content in general.  I also love the fact it natively support OpenGL which I have a lot of previous experience with.

After playing a little, I realized this is a very intuitive and powerful project structure in Eclipse.  They have done a great job with how the generated class files and resources are defined and better yet, the way the resources are referenced in the XML and code is brilliant.  For instance, I started messing around with graphics and the first thing I had to do it create a custom view and then reference that custom view in the layout XML.  You do this by extending android.view.View and then overriding the onDraw() event.  Viola, you instantly have a custom view for your own graphics drawing!

This is what I like best, you reference your custom view in the XML by specifying the class name as the element name:

<net.balfes.views.custom.MainView
 android:id="@+id/ViewPort"
 android:layout_width="wrap_content"
 android:layout_height="wrap_content"/>

So what I did was lay out a simple checkers user interface and then started playing with the different listeners and graphics API’s.

2 thoughts on “Learning the Android SDK

  1. Funny because I could write almost the same post 🙂

    Just started to play with the Android SDK. And it’s pretty.
    Very easy to learn.
    I played with SQLite, Google Maps, Reminders…
    Integration with Google Maps is very well done.

    I like a lot the use of XML too.

    Like

  2. Pingback: Intents have lots of applications » Balfes.net

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s