Search code examples
androidgoogle-chromechrome-custom-tabs

Chrome Custom tabs killing my activity


I am using Chrome Custom tabs to display a webview : all works well.

If the user click the "close" button, the activity which launched the tab is not revived and the user see nothing but the "main screen" of my Android.

The launching intent is configured this way :

CustomTabsHelper.AddKeepAliveExtra(ParentActivity, customTabsIntent.Intent);

The launching activity has this definition in the manifest :

<activity android:label="StartupView" android:noHistory="true" android:screenOrientation="portrait" android:name="md533c5c955946a288d55ba44dbb1f39685.StartupView">
      <intent-filter>
        <action android:name="android.intent.action.VIEW" />
        <category android:name="android.intent.category.BROWSABLE" />
        <category android:name="android.intent.category.DEFAULT" />
        <data android:scheme="jonathanantoinetvstandroid" />
      </intent-filter>
</activity>

Can you help me :) ?


Solution

  • So I figured out the issue I was facing : I was settings android:noHistory="true" in my "launching activity". So be sure to set it to false.