Niels
Niels

Reputation: 299

Filter out older devices using manifest

I'm developing an app that's intended for high-end devices only. It already only supports API 17+ but I've noticed some older devices that run API 17 that I'd like to exclude. My question is:

What's the best way to filter out older devices that still run a relatively new Android version?

I'd like to avoid manually excluding specific devices in Google Play.

Filtering based on screen density
One thing that I'd certainly like to do is filter on screen density (I'd like to support only hdpi and higher). I've read the compatible-screens article but I don't really like the solution presented there because:

  1. According to the article: "You should use it only as a last resort, when the application absolutely does not work with specific screen configurations."
  2. I'll get a large list of combinations in my manifest (if I support hdpi, xhdpi, xxhdpi and xxxhdpi with screen sizes medium, large and xlarge I'll already have 12 combinations).
  3. What if a new screen density (e.g. xxxxhdpi) or a new screen size (e.g. xxlarge) is added? To support those I'd have to update my manifest every time a new bucket is added.

It seems strange to me that I can't just specify that I want to support hdpi and higher in a single line in the manifest.

Filtering based on device features
I've also considered filtering on some feature that only high-end devices have, so I read the uses-feature article. However, it seems that I can only filter on things like bluetooth, camera and wi-fi and not on anything more indicative of a high-end device like hardware acceleration.

Upvotes: 1

Views: 764

Answers (1)

SMR
SMR

Reputation: 6736

You just can't filter out specific device(s) using the AndroidManifest.xml file itself except the screen size/density etc. say if you need to filter out a specific handset/tablet for a specific vendor then is will not be possible using the manifest file only.

"What is the best way to filter out older devices that still run a relatively new Android version?"

Solution: There are options in Google Play Developer Console by which you can filter specific devices (handsets/tablets/models etc) according to vendor and model number for a particular app you have published.

To do this goto the APK section of your app:

enter image description here

Now click either on See List or Manage excluded devices the usage is very easy and self explanatory. This show show something like this:

enter image description here

Now All you need to do is just click on the enter image description here button and it will be added to the Excluded Devices.

Hope it helps :)

Upvotes: 1

Related Questions