当前位置: 动力学知识库 > 问答 > 编程问答 >

Android humidity sensor manifest

问题描述:

I want to use the uses-feature in android to limit my app to only be visible on the play store to devices with a humidity sensor, but I cant find on developer.android.com what the delimited would be for that sensor.

I know that for accelerometer is like this:

<uses-feature

android:name="android.hardware.sensor.accelerometer"

android:required="true" />

网友答案:

There is no way to do that using <uses-feature>

Read here about <uses-feature>.

I know alternative solution : when user turn on application, you're getting a list of sensors and if there is not hydrometr, you're showing toast :

"You cannot use that application, because your device hasn't got required sensor"

分享给朋友:
您可能感兴趣的文章:
随机阅读: