Я создаю это приложение для Twitter, где браузер вызывается для аутентификации из моего основного вида деятельности. запуск следующего кода в потоке (AsyncTask)
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);
здесь
context is the context of main activity..the uri is returned through `intent`..
После аутентификации, что нужно сделать, это вернуться к моей основной деятельности, к ее нынешнему состоянию. Что происходит сейчас, это создает еще один экземпляр основной деятельности.
Я использую
@Override
public void onNewIntent(Intent intent) {
    super.onNewIntent(intent); 
    SharedPreferences prefs = getSharedPreferences("twitter", 0);
    final Uri uri = intent.getData();
    if (uri != null && uri.getScheme().equals(Constants.OAUTH_CALLBACK_SCHEME)) {
        setLoggedIn(true, tlogout);
        tstatus=true;
        new RetrieveAccessTokenTask(this,consumer,provider,prefs,tstring).execute(uri);
    }
}
но все же проблема остается... другая вещь, все отлично работает в эмуляторе (2.3). Не работает в моем устройстве... Android 2.3.6
Мой манифест
<activity
    android:name=".mainActivity"
    android:launchMode="singleTask"
    android:label="@string/title_activity_main" >
    <intent-filter>
        <action android:name="android.intent.action.VIEW" />
            <category android:name="android.intent.category.DEFAULT" />
            <category android:name="android.intent.category.BROWSABLE" />
            <data android:scheme="x-oauthflow-twitter" android:host="callback" />
    </intent-filter>
</activity>