I have 2 apps. App A and App B has only BActivity ( App B's Package is : com.ts.share). From App A , i'd like to start App B. In App A, i called
Intent LaunchIntent = getPackageManager().getLaunchIntentForPackage("com.ts.share");
LaunchIntent.setFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP |Intent.FLAG_ACTIVITY_NEW_TASK);
startActivity( LaunchIntent );
It worked fine.
At B, If exit B, go to A, and call again. It took 0s to start App B.
But At B, press Home button, go to A, and call again. It took 3 s to start App B.
I want to App B start immediately.
I appreciate your help!