Either .. or the difference in the Android manifest <uses-feature>

I am developing an Android application and need either the hardware function android.hardware.camera.flash or android.hardware.camera.front . I want to assure that this application will be available for smartphones that have a flashlight but no front camera. How can I achieve this?

Thank you in advance

+4
source share
1 answer

I do not believe that there is a way to explicitly insert a restriction of β€œeither” or β€œ. You can add android:required="false" for both <uses-feature> elements, but then you will get devices that lack both functions.

I want to assure that this application will be available for smartphones that have a flashlight but no front camera.

Have android:required="true" in the android.hardware.camera.flash function and android:required="false" in the android.hardware.camera.front function.

+1
source

All Articles