Commit 841e5c22 authored by Boris Sazonov's avatar Boris Sazonov Committed by Commit Bot

[Signin][Android] Use support library fragments in SigninActivity

This is a follow-up to https://crrev.com/c/980335.
This CL migrates SigninActivity and SigninFragmentBase to support
library fragments (android.support.v4.app.Fragment instead of
android.app.Fragment).

Bug: 825789, 814728
Change-Id: I76d8a5eb329e9b418d1ae1c75a8d272d2b7c6009
Reviewed-on: https://chromium-review.googlesource.com/982054Reviewed-by: default avatarTheresa <twellington@chromium.org>
Commit-Queue: Boris Sazonov <bsazonov@chromium.org>
Cr-Commit-Position: refs/heads/master@{#546121}
parent 77585f14
...@@ -4,11 +4,11 @@ ...@@ -4,11 +4,11 @@
package org.chromium.chrome.browser.signin; package org.chromium.chrome.browser.signin;
import android.app.Fragment;
import android.app.FragmentManager;
import android.content.Context; import android.content.Context;
import android.content.Intent; import android.content.Intent;
import android.os.Bundle; import android.os.Bundle;
import android.support.v4.app.Fragment;
import android.support.v4.app.FragmentManager;
import android.support.v7.app.AppCompatActivity; import android.support.v7.app.AppCompatActivity;
import org.chromium.base.Log; import org.chromium.base.Log;
...@@ -51,7 +51,7 @@ public class SigninActivity extends AppCompatActivity { ...@@ -51,7 +51,7 @@ public class SigninActivity extends AppCompatActivity {
super.onCreate(savedInstanceState); super.onCreate(savedInstanceState);
setContentView(R.layout.signin_activity); setContentView(R.layout.signin_activity);
FragmentManager fragmentManager = getFragmentManager(); FragmentManager fragmentManager = getSupportFragmentManager();
Fragment fragment = fragmentManager.findFragmentById(R.id.fragment_container); Fragment fragment = fragmentManager.findFragmentById(R.id.fragment_container);
if (fragment == null) { if (fragment == null) {
fragment = new SigninFragment(); fragment = new SigninFragment();
......
...@@ -5,11 +5,11 @@ ...@@ -5,11 +5,11 @@
package org.chromium.chrome.browser.signin; package org.chromium.chrome.browser.signin;
import android.annotation.SuppressLint; import android.annotation.SuppressLint;
import android.app.Fragment;
import android.graphics.drawable.Drawable; import android.graphics.drawable.Drawable;
import android.os.Bundle; import android.os.Bundle;
import android.support.annotation.Nullable; import android.support.annotation.Nullable;
import android.support.annotation.StringRes; import android.support.annotation.StringRes;
import android.support.v4.app.Fragment;
import android.support.v7.content.res.AppCompatResources; import android.support.v7.content.res.AppCompatResources;
import android.text.method.LinkMovementMethod; import android.text.method.LinkMovementMethod;
import android.view.LayoutInflater; import android.view.LayoutInflater;
......
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