background preloader

Android

Facebook Twitter

GameDev

350+ Fresh And Elegant Free Icons For Android - Ntt.cc - jotarun's posterous. OpenGLES. Android Development. How to create a custom titlebar. If you got sick and tired of the default style/behavior of the title bar in your apps, or just need something different, than here is a little snippet for You.

How to create a custom titlebar

It has 2 textviews, and a progress bar in it. It needs 2 parameters: String left, String right, these are the texts that will be displayed. Usually, the left one is the app name, the right one is dynamic. So if the right one is longer than 20 characters, it will be truncated. Here is the layout: Here is the code: boolean customTitleSupported;public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); //check if custom title is supported BEFORE setting the content view!

Android Preferences. Android Client-side OAUTH. Posted by Don 24 Jan 2009 at 07:37PM OAUTH is a system for allowing users to manage third-party access to protected resources on a trusted provider. The OAUTH provider in this case is a Ruby on Rails web application that records location data. The "third-party" is an Android mobile application playing the role of the OAUTH consumer.

The cell phone owner is the user that gives permission to the provider to allow the third party, here after called the consumer, to access protected resources. Android Client-side OAUTH. Android – Multithreading in a UI environment. Why do we need multithreading in Android applications?

Android – Multithreading in a UI environment

Let’s say you want to do a very long operation when the user pushes a button. If you are not using another thread, it will look something like this: What will happen? The UI freezes. This is a really bad UI experience. The problem in using threads in a UI environment So what will happen if we use a Thread for a long running operation. The result in this case is that the application crashes.12-07 16:24:29.089: ERROR/AndroidRuntime(315): FATAL EXCEPTION: Thread-8 12-07 16:24:29.089: ERROR/AndroidRuntime(315): android.view.ViewRoot$CalledFromWrongThreadException: Only the original thread that created a view hierarchy can touch its views. 12-07 16:24:29.089: ERROR/AndroidRuntime(315): at ...

Clearly the Android OS wont let threads other than the main thread change UI elements. But why? The solution A queue of messages. The same solution was implemented in swing (Event dispatching thread and SwingUtilities.invokeLater() ) How to use Gmail as your SMTP server. Go Public with Your Android Application: Signing and Deployment. O far, you've been learning about the interesting things you can do with Android.

Go Public with Your Android Application: Signing and Deployment

However, if you want your application to see the light of day and run on other users' devices, you need a way to distribute your application and deploy them onto your target devices. This article will show you how to prepare your Android applications for deployment and get them onto your customers' devices. Java, Programming, and Other Technical Musings. I have just done the necessary setup to do some Android development on my Fedora 12 machine using Eclipse (Galileo) and the Android SDK.

Java, Programming, and Other Technical Musings

As i have a HTC Dream (or G1) with me, i also wanted to deploy and test directly on the phone itself instead of using an emulator. However, things didn't go very smoothly when trying to connect to the phone through ADB. What i had done to that point was: 1. Created a simple Hello World Android application. 2. 3. However, when i tried to run the application, the Android Device Chooser (i had set the Deployment Target Selection Mode to Manual) showed this: And of course, i couldn't run the application even after selecting the "unknown" target. Doing a adb devices on the command line also showed a problem: $ . It turned out that this was quite a common problem (at least for those developing in Linux), and quite a number of pages (references at the end of article) were devoted to solving (or actually, working around) it. ADB and Pulse Mini - Android @ MoDaCo. Cantido, on Aug 23 2010, 12:31, said: Sorry for the delay...

ADB and Pulse Mini - Android @ MoDaCo

My pulse mini gives this description.USB description data (for identification) ------------------------- Manufacturer: Huawei Incorporated Product: T-Mobile 3G Phone Serial No.: not provided -------------------------It's possible your firmware will need a different message to do the mode switch. If you have virtual box and a windows xp vm you can easily capture the message using a usb sniffer. Hi, I am getting the problem described in this thread with my phone. I had similar output to cantido, where it keeps waiting for the original device to vanish. How to set location on emulator. Testing - How to emulate gps location in the android Emulator. Android Developers Blog. Code University - Google Code.

Developers.