Fixes issue #2
by removing singleinstance from MainActivity in the manifest and handling the launch in AppShortcutLauncherActivity
This commit is contained in:
parent
4170e00cfd
commit
d17f0407dd
2 changed files with 6 additions and 3 deletions
|
|
@ -84,6 +84,9 @@ public class AppShortcutLauncherActivity extends Activity {
|
|||
//Put the bundle in the intent
|
||||
intent.putExtras(bundle);
|
||||
|
||||
//If MainActivity's already running, don't launch another instance. Instead, bring it to the top and deliver the intent to onNewIntent()
|
||||
intent.addFlags(Intent.FLAG_ACTIVITY_CLEAR_TOP | Intent.FLAG_ACTIVITY_SINGLE_TOP | Intent.FLAG_ACTIVITY_NEW_TASK);
|
||||
|
||||
//Finally, start MainActivity with those extras
|
||||
startActivity(intent);
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue