Closing Browser window after twitter login android with twitter4J 3.0.5


#1

Hi I am developing android application in which I am using twitter login. I am using twitter4j-3.0.5 lib for twitter authentication. So my scene is like this after login successful it come back to my application but in background it is not closing browser window. when I click back my browser with twitter window is still there.

My code looks like this:

Intent intent = new Intent(Intent.ACTION_VIEW,Uri.parse(requestToken.getAuthenticationURL()));
startActivity(intent);



<category android:name="android.intent.category.DEFAULT" />
<category android:name="android.intent.category.BROWSABLE" />

<data
    android:host="com.example.twitterapp"
    android:scheme="oauth" />
</intent-filter>
I want to close that web browser. Is there any one can help me please ? Need Help. Than you.