Welcome to the official BlackBerry Support Community Forums.

This is your resource to discuss support topics with your peers, and learn from each other.

inside custom component

Android™ Development

Posts: 10
Registered: ‎05-20-2013
My Device: Blackberry q10
My Carrier: reliance
Accepted Solution

How to detect if the Android app is the Blackberry repackaged version?

My application can be easily repackaged for blackberry devices using their web portal.



So I can turn my .apk file into a .bar file that users can install on their BB10 devices.


My concern now would be to slighty change the UI or disable some features (in-app billing, Google Maps, some intents) regarding the OS.


I would like for instance to display a Map button on legit Android devices and remove this button on the Blackberry port. I also have some preferences related to the widget that have no reason to appear on a BB10 device

Do you know a perfect way to detect if the app is the repackaged one or the original apk?


My guess would be to use the Build information, but I am pretty sure there is a better way to achieve this.

Posts: 48
Registered: ‎06-24-2010
My Device: Storm 2
My Carrier: Orange

Re: How to detect if the Android app is the Blackberry repackaged version?



    public static boolean isBlackBerry() {
        return java.lang.System.getProperty("os.name").equals("qnx");