0

Hey I have made a browser app for android, but now I need to give the user a change to set my browser as default.

EDIT: I have tried to use this code in my manifest but with nu luck

<intent-filter> <action android:name="android.intent.action.VIEW"></action> <category android:name="android.intent.category.DEFAULT"></category> <category android:name="android.intent.category.BROWSABLE"></category> </intent-filter> 

But with no luck

1

1 Answer 1

1

Try to add following XML to your main activity to make your app a candidate for intent sent by other apps that look for loading a page into the browser with startActivity(new Intent("android.intent.action.VIEW", Uri.parse("http://....")));

<intent-filter> <action android:name="android.intent.action.VIEW"></action> <category android:name="android.intent.category.DEFAULT"></category> <category android:name="android.intent.category.BROWSABLE"></category> </intent-filter> 
Sign up to request clarification or add additional context in comments.

1 Comment

can still not make it as my default browser

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.