Fix Android app stuck in splash screen when killed by the OS (#1403)

This commit is contained in:
enahum
2018-02-01 11:56:09 -03:00
committed by Harrison Healey
parent 05587d789a
commit cd6fd9017f
2 changed files with 8 additions and 0 deletions

View File

@@ -93,6 +93,13 @@ public class MainApplication extends NavigationApplication implements INotificat
SoLoader.init(this, /* native exopackage */ false);
}
@Override
public boolean clearHostOnActivityDestroy() {
// This solves the issue where the splash screen does not go away
// after the app is killed by the OS cause of memory or a long time in the background
return false;
}
@Override
public IPushNotification getPushNotification(Context context, Bundle bundle, AppLifecycleFacade defaultFacade, AppLaunchHelper defaultAppLaunchHelper) {
return new CustomPushNotification(