Search code examples
androidandroid-4.0-ice-cream-sandwichbackwards-compatibilityandroid-2.3-gingerbread

Almost finished with my first Android application made with Ice Cream Sandwich and was wondering about backwards comptibility


Hello I have developed my first application for Android using the Ice Cream Sandwich SDK and I was wondering if there was a way to make this compatible for devices also running Gingerbread without having to re-do the entire program. I have tried to find the answer to this from other sources but haven't found anything yet. Thank you for your time.


Solution

  • Congratulations for the development of your first application ;) It's difficult to answer to your questions without knowing what your application is using. If your application use new features of the Android ICS API, you have to implements some compatibility code (see Support package). If not, you just need to add this in your AndroidManifest.xml :

    <uses-sdk
        android:targetSdkVersion="14"
        android:minSdkVersion="7"
    />
    

    Note that 7 is for Android 2.1

    The best way to know if you use specific API of Android 4 (ICS) is to try to launch your project on an emulator under a lower version. If this give you error(s), it's because you have compatibility problems.