Home » Android » Is there a way to hide the Android Device Chooser?

Is there a way to hide the Android Device Chooser?

Posted by: admin June 15, 2020 Leave a comment


Whenever I run my app I get the Android Device Chooser dialog:

alt text

This is happening because I am using the Google APIs for 1.6 and trying to run the application on my Nexus one. Is there any way to make this automatically, or to not check the compatibility? Sometimes when I make a modification and quickly after I save and run the application, Eclipse will build the project and the Android Device Chooser dialog will show briefly and disappear and the app won’t run. I have to click run again for it to work. Any workarounds?

How to&Answers:

Once you have installed ADT, you need to define an ADT launch configuration, in order for your project to execute itself as an Android executable.

(source: google.com)

Then, do not forget to To go in Eclipse->Preferences->Run/Debug->Launching.
In the “Launch Operation” subsection, select “Always launch the previously launched application”:

(source: turbulent.ca)


Create a run configuration.

Run -> Run Configurations.

Select your project and specify your target and from then on run that configuration when you run that app.


The key is the very top line in the screen shot of your Android Device Chooser. Notice that it is asking you to select a device compatible with a Google API target. This dialog only ignores your launch preference when the Android version you selected in your project’s properties is one of the “GoogleAPIs” type. Choosing one of the Android Open Source Project versions will respect your launching preferences.


This is a bug (or intentional behavior) in ADT when anything other than a stock SDK version is selected. You will experience this when targeting “Google APIs” rather than a plain Android SDK.

For the details, see the implementation of AndroidLaunchController.java within the adt project. (Basically, whenever you target something other than a plain SDK, it can’t tell if the attached device satisfies the requested libraries, in this case Google APIs.)


Just set the ‘target’ tab to the ‘Automatic’ option and it will launch on your device automatically.