StartupHandler.java: Finish main activity if AutoStartFile is specified in intent

Call finish() on parent (main/browser) activity after starting EmulationActivity if AutoStartFile was specified. This makes the experience more streamlined for users who want to start games from an external frontend, since they don't expect to return to the Dolphin main activity after they've played their game.
This commit is contained in:
Kim Johnsson 2016-01-05 13:55:30 +01:00
parent 0da8bd0f61
commit 204201bcbc

View file

@ -42,10 +42,11 @@ public final class StartupHandler
if (!TextUtils.isEmpty(start_file))
{
// Start the emulation activity and send the ISO passed in.
// Start the emulation activity, send the ISO passed in and finish the main activity
Intent emulation_intent = new Intent(parent, EmulationActivity.class);
emulation_intent.putExtra("SelectedGame", start_file);
parent.startActivity(emulation_intent);
parent.finish();
return false;
}
}