Reputation: 3732
If I use ARCWelder to port my app to Chrome, is there a way for it to know that it's running on Chrome? Maybe through BUILD.Version?
Upvotes: 2
Views: 839
Reputation: 71
//Check for brand and manufacturer
if(Build.BRAND.equals("chromium") && Build.MANUFACTURER.equals("chromium")){
/*Code to be executed if app is running on chromium*/
}
Upvotes: 2
Reputation: 1007584
Quoting the documentation:
If you need to check if your app is running on Chrome OS, look for chromium as the android.os.Build.BRAND and android.os.Build.MANUFACTURER.
Upvotes: 3