I am developing an application where i have integrated Twitter in TabActivity. I have not created another activity, I am calling intent from TabActivity(Where we add all tabs), If I call intent from another activity it shows black screen. For this i call intent from TabActivity. Now it is not showing black screen but it is not returning to onNewIntent Function, instead of this onCreate of TabActivity is called.
<activity android:name=".guide.Tab_Custom" android:windowSoftInputMode="adjustPan">
<intent-filter><action android:name="android.intent.action.VIEW" /><category ndroid:name="android.intent.category.DEFAULT" /><category android:name="android.intent.category.BROWSABLE" /><data android:scheme="x-oauthflow-twitter" android:host="callback" /></intent-filter> </activity>
Here is code of calling intent:
try {
final String url = provider.retrieveRequestToken(consumer, Twitter_Constants_Key.OAUTH_CALLBACK_URL);
Intent intent = new Intent(Intent.ACTION_VIEW, Uri.parse(url)).setFlags(Intent.FLAG_ACTIVITY_SINGLE_TOP | Intent.FLAG_ACTIVITY_NO_HISTORY | Intent.FLAG_FROM_BACKGROUND);
context.startActivity(intent);
} catch (Exception e) {
Log.e(TAG, "Error during OAUth retrieve request token", e);
}
Any idea will be appreciated.
Thanks