Fix PIN screen title

Set the header text of the screen after Activity.setTitle is called,
so that the PIN screen will show the PIN text as header, as opposed to
the default which is always "password".

Bug: 30041779
Change-Id: I525bd4e5c51252410fdeb0424329bbfbd86e5b7d
This commit is contained in:
Maurice Lam
2016-07-08 18:38:48 -07:00
parent 94c8f7ea7e
commit 44f2736f54

View File

@@ -290,10 +290,7 @@ public class ChooseLockPassword extends SettingsActivity {
@Override
public View onCreateView(LayoutInflater inflater, ViewGroup container,
Bundle savedInstanceState) {
GlifLayout layout = (GlifLayout) inflater.inflate(
R.layout.choose_lock_password, container, false);
layout.setHeaderText(getActivity().getTitle());
return layout;
return inflater.inflate(R.layout.choose_lock_password, container, false);
}
@Override
@@ -365,6 +362,7 @@ public class ChooseLockPassword extends SettingsActivity {
: R.string.lockpassword_choose_your_pin_header;
CharSequence title = getText(id);
sa.setTitle(title);
((GlifLayout) view).setHeaderText(title);
}
}