thecr0w
thecr0w

Reputation: 2197

FragmentActivity on Android 1.5

I have included android.support.v4.jar in my libs, but is still not compatible with 1.5. How can I achieve it?

logs: E/AndroidRuntime(800): java.lang.VerifyError: android.support.v4.app.FragmentActivity

Upvotes: 0

Views: 467

Answers (3)

Chirag
Chirag

Reputation: 56925

Its Supported Minimum API level : 4 . Android 1.6

Look Here for More Details.

Look Here the Market Share of Android Versions.

Android SDK version table for Septmber 4 2012.

Android SDK version      Current market share   
1.5 (Cupcake)               0.1 %       
1.6 (Donut)                 0.1 %       
2.1 (Eclair)                4.0 %   
2.2 (Froyo)                 13.1 %      
2.3 (Gingerbread)           49.7 %      
3.0-3.2 (Honeycomb)         1.8 %       
4.0.x (ICS)                 28.5 %      
4.1 (Jelly Bean)            2.6 %       

Upvotes: 2

Sahil Mahajan Mj
Sahil Mahajan Mj

Reputation: 11141

Fragments not supported in Android 1.5. Minimum API level for using Fragments is 4.

Upvotes: 1

Cat
Cat

Reputation: 67502

The documentation states:

Minimum API level supported: 4

API 4, of course, is Android 1.6 Donut. There is also a support library that is only compatible with v13 (Honeycomb 3.2) and up.

It is definitely worth nothing that it is almost unnecessary to support Android 1.5 at this time. Only 0.2% of devices run it (that's 2 in every 1,000 downloads) as of the writing of this post. And the demographic of that 0.2% will probably be largely A) developers and B) people who don't use a whole lot of apps, as they're more likely to stick to older technology.

So, you have three options:

  1. Bump up your minSdkVersion to 4, and scrap support for 3 (1.5).
  2. Use a version check to see if the version is 4+. (I don't recommend this. It gets very unmaintainable.)
  3. Don't use anything from the support library. (Again, this seems silly, to scrap functionality over loss of 2/1,000 users.)

Upvotes: 2

Related Questions