Commit 643badcc authored by Boris Sazonov's avatar Boris Sazonov Committed by Commit Bot

[First Run][Android] Change the animation at the end of the FRE

This CL changes the animation used for the transition from FRE activity
to the activity that has triggered the FRE - now fade-out/fade-in
transition is used instead of the default sliding transition. This looks
better (especially for dialog-based FRE) and allows code simplification
(no more need to disable the animation for TabbedModeFirstRunActivity).

Bug: 945284
Change-Id: I8ae9e7d32cef5115ce617455dc24b970d73c1aa0
Reviewed-on: https://chromium-review.googlesource.com/c/chromium/src/+/1537113
Auto-Submit: Boris Sazonov <bsazonov@chromium.org>
Reviewed-by: default avatarMatthew Jones <mdjones@chromium.org>
Commit-Queue: Boris Sazonov <bsazonov@chromium.org>
Cr-Commit-Position: refs/heads/master@{#644520}
parent ed21a685
......@@ -116,6 +116,8 @@ public abstract class FirstRunActivityBase extends AsyncInitializationActivity {
// Use the PendingIntent to send the intent that originally launched Chrome. The intent
// will go back to the ChromeLauncherActivity, which will route it accordingly.
pendingIntent.send(Activity.RESULT_OK, onFinished, null);
// Use fade-out animation for the transition from this activity so the original intent.
overridePendingTransition(android.R.anim.fade_in, android.R.anim.fade_out);
return true;
} catch (CanceledException e) {
Log.e(TAG, "Unable to send PendingIntent.", e);
......
......@@ -87,11 +87,6 @@ public class FreIntentCreator {
final Class<?> activityClass;
if (shouldSwitchToTabbedMode(context)) {
activityClass = TabbedModeFirstRunActivity.class;
// Going to launch TabbedModeFRE. Have to disable animation on the intent launched after
// the FRE is completed to make the transition seamless.
intentToLaunchAfterFreComplete = new Intent(intentToLaunchAfterFreComplete);
intentToLaunchAfterFreComplete.addFlags(Intent.FLAG_ACTIVITY_NO_ANIMATION);
} else {
activityClass = FirstRunActivity.class;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment