Arkadaşlar superview kullanıyorum user agent tanımlamam lazım bir türlü android studio ile nereye ne yazacağımı bulamadım.
public boolean onDrawerItemSelected(View view, int position) {
String url = Config.URLS[position];
if (WebToAppWebClient.urlShouldOpenExternally(url)){
try {
view.getContext().startActivity(
new Intent(Intent.ACTION_VIEW, Uri.parse(url)));
} catch(ActivityNotFoundException e) {
if (url.startsWith("intent://")) {
view.getContext().startActivity(
new Intent(Intent.ACTION_VIEW, Uri.parse(url.replace("intent://", "http://"))));
} else {
Toast.makeText(this, getResources().getString(R.string.no_app_message), Toast.LENGTH_LONG).show();
}
}
return false;