App A has an main activity that launch mode set as standard, open it. When I reopen it from system launcher, everything looks normal. But if start app A through another app B, A restart! Why?
My code:
Intent launchIntent = getPackageManager().getLaunchIntentForPackage("A's package name");
launchIntent.setAction(Intent.ACTION_MAIN);
launchIntent.addFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
launchIntent.addCategory(Intent.CATEGORY_LAUNCHER);
startActivity(launchIntent);