android-2.2

Why won't a Android 1.5 app run on Android 2.2 phone or emulator?

I'm developing an Android application using Android 1.5. I'm using an older version of the SDK because I'm building it to run on a single G1 phone. I've been using a 2.1 emulator without any problems, but when I tried taking a look on my Nexus One (2.2), the application immediately stopped responding. I then tried a 2.2 emulator with th...

Android; How does the manageQuery work in 2.2?

I'm trying to display contact information, and from another question on stackOverflow I've got the following snippet String[] projection = new String[] { ContactsContract.Contacts.DISPLAY_NAME, ContactsContract.CommonDataKinds.Phone.DISPLAY_NAME, ContactsContract.CommonDataKinds.Email.DISPLAY_NAME }; Ur...

Android 2.2; Can you query from 2 different URIs at the same time?

If you want to obtain contacts data from two separate URIs, can you do this in a single query? For example : ContentResolver cr; Cursor emailCur = cr.query( ContactsContract.CommonDataKinds.Email.CONTENT_URI, null, null, null); Should return all available columns ag...

Android; Pulling out contact info, should you map to custom domain class or is there one provided?

When picking out contact details, is there a built in domain class they can be mapped to? Or, do you have to create your own? For example I do the following : ContentResolver cr = getContentResolver(); Cursor cur = cr.query(ContactsContract.Contacts.CONTENT_URI, null, null, null, null); String s = null; if (cursor.getCount() >...

Android; I only have 2 contacts, yet I can obtain 5 from a query, why?

I have setup 2 test contacts in my emulator. I'm running the following query, it should pick them both out, populate my domain object, and add to a list. The output at the bottom should therefore be 2, but it is 5, why is this? (cursor.getCount() is 5 instead of 2) I have stepped through each iteration of the while loop and it is retre...

Android; MapView, how can I set default location?

Using the MapView in android, how can I set a default location, so that everytime I load up this application, it automatically centers/zooms location in on London? ...

Android; Geocoder, why do I get "the service is not available"?

I want to use the Geocoder in an android application, I've got the following piece of code to sample it : public class LocatorGeo extends Activity { /** Called when the activity is first created. */ @Override public void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView...

Is/Are there any standard package structuring/heirarchy practices for Android?

When developing J2EE web applications I would typically organise my package structure in the following way com.jameselsey.<applicationName>. Controller - Controllers/Actions go here Service - transactional service classes, called by Controllers Domain - My domain classes/objects that the application uses DAO - abstract DAO layer DAOIm...

Settings Action constant for Tethering settings page in Android 2.2 (Froyo)

Hello, I am able to open Wifi settings screen using startActivity(new Intent(Settings.ACTION_WIRELESS_SETTINGS)); I want to open the tethering and hotspot settings page using the same.Can anyone tell me the settings value i have to use instead of ACTION_WIRELESS_SETTINGS. Thanks Dheepak ...

Android; How can I initialise state in one activity, then have another refresh that?

I have two activities The first one gets some data from a content provider, and displays it The second activity has a button, and when clicked it should call the first activity to "refresh", in other words to reload data from the content provider This is my first activity ... @Override public void onCreate(Bundle savedInstanceSta...

How to add IntentFilter in an Activity by code?

i have this activity that holds 2 intent filters and my problem is not to use this activity for devices 1.6 and before since i wanted them to use the native contacts. thanks! ...

Can you load flash into a webview being loaded by an android app

I am testing this on a Droid X with Android 2.2 and flash. Flash works great in the default android browser, but the webview does not seem to load it, even when linking to an external web hosted html file. ...

Android ContactsContract.Contact missing constants from the API?

I've been using the ContactsContract api for some time now and I've come across two "columns" listed in the API page for ContactsContract.Contacts that do not appear to actually be assessable. The values are (under the columns heading): "NAME_RAW_CONTACT_ID" and "DISPLAY_NAME_PRIMARY" By my reading of the API these two values would see...

If I license my app with GNU GPL3, does that prevent me from selling it on android market?

I'm using Google Code to host my application code, its conveniant and the SVN repository means I don't have to worry about backups When you create a project on there you need to select a license, I chose GNU GPL v3. By doing so, does that prevent me from selling my application on the Android market place? ...

Upgrading and Application from Android 1.6 to Android 2.2 does not work

Hi, I currently found out, that my Application developed for Android 1.6 does not work on Android 2.2. I'm quite puzzled about this, because its a very simple Application which almost does nothing. The Expeption I get is like that: java.lang.RuntimeException: Unable to instantiate application [packagename].AndApp: java.lang.ClassNotFo...

Android 2.2.1 Nexus one : Voice recognition problem

HI Folks, I have a strange problem for Voice recognition on Google Nexus one phone which have Firmware:2.2.1.Voice recognition gives multiple interpretations of the spoken word When I speak "Hello" to the voice recognition, the results received is "hello, hotels, photos, fomdem, honda" which is expected to come only "hello" The same thi...

Android; are there any changes between 2.1 and 2.2 that developers need to be aware of with backwards compatability?

I've created a few applications that have been targetted against 2.2 I'm thinking to invest in a cheap handset to try these out (thus far only used emulator). The handset I want is running verion 2.1 of Android. From a code point of a view, is there any major changes between 2.1 and 2.2 that could potentially cause me an issue? I unde...

notifydatasetchanged not working in android 2.2 but works in 1.6 fine (and I believe 2.1)

This is a clearer and more precise definition (with test code) of the problem originally detailed here http://stackoverflow.com/questions/3814392/app-working-under-2-1-android-now-hangs-on-2-2-both-in-emulator-and-desire. I have narrowed the cause of the problem down to a call to notifyDataSetChanged(). The code works fine in versions p...

How reliable is Android 2.2

Its been around 2 years since Android's first release and already there are 6 to 7 Android releases, unlike Windows mobile. And I found between 2.1 and 2.2 there are lots of changes. The way to call my local services, and other methods have been deprecated etc.. So how stable is Android 2.2. Are we gonna have more frequent release? Deve...

Mediaplayer plays weird sounds on Android 2.2

Hello! I've created an app that uses MediaPlayer to play a random (short) sound when a button is clicked. The sounds are played correctly on android devices < 2.2. This is the code responsible for playing sounds. r = new Random(); sounds = new ArrayList<MediaPlayer>(); sounds.add(MediaPlayer.create(this, R.raw.sound1)); sounds.add(Media...