Show keyboard selectively, do not listen on MCC/MNC changes, show text to user.
Fix b/6531158 (Stop showing the keyboard) Fix b/6532201 (Stop removing the text view, and prompt the user with a message) Fix b/6155075 (Stop listening to MCC/MNC changes) Change-Id: Ibf8414fe57bdd0acf6c20f3194c52b168b9292c6
This commit is contained in:
@@ -1416,8 +1416,8 @@
|
|||||||
android:launchMode="singleTop"
|
android:launchMode="singleTop"
|
||||||
android:excludeFromRecents="true"
|
android:excludeFromRecents="true"
|
||||||
android:theme="@android:style/Theme.Holo.NoActionBar"
|
android:theme="@android:style/Theme.Holo.NoActionBar"
|
||||||
android:configChanges="mcc|mnc|keyboard|keyboardHidden|uiMode"
|
android:configChanges="keyboard|keyboardHidden|uiMode"
|
||||||
android:windowSoftInputMode="stateVisible|adjustResize">
|
android:windowSoftInputMode="adjustResize">
|
||||||
<intent-filter android:priority="10">
|
<intent-filter android:priority="10">
|
||||||
<action android:name="android.intent.action.MAIN" />
|
<action android:name="android.intent.action.MAIN" />
|
||||||
<category android:name="android.intent.category.HOME" />
|
<category android:name="android.intent.category.HOME" />
|
||||||
|
@@ -170,8 +170,6 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList
|
|||||||
} else {
|
} else {
|
||||||
final TextView status = (TextView) findViewById(R.id.status);
|
final TextView status = (TextView) findViewById(R.id.status);
|
||||||
status.setText(R.string.try_again);
|
status.setText(R.string.try_again);
|
||||||
status.setVisibility(View.VISIBLE);
|
|
||||||
|
|
||||||
// Reenable the password entry
|
// Reenable the password entry
|
||||||
mPasswordEntry.setEnabled(true);
|
mPasswordEntry.setEnabled(true);
|
||||||
}
|
}
|
||||||
@@ -472,13 +470,11 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList
|
|||||||
// Re-enable the password entry and back presses.
|
// Re-enable the password entry and back presses.
|
||||||
mPasswordEntry.setEnabled(true);
|
mPasswordEntry.setEnabled(true);
|
||||||
mIgnoreBack = false;
|
mIgnoreBack = false;
|
||||||
status.setVisibility(View.GONE);
|
status.setText(R.string.enter_password);
|
||||||
} else {
|
} else {
|
||||||
CharSequence template = getText(R.string.crypt_keeper_cooldown);
|
CharSequence template = getText(R.string.crypt_keeper_cooldown);
|
||||||
status.setText(TextUtils.expandTemplate(template, Integer.toString(mCooldown)));
|
status.setText(TextUtils.expandTemplate(template, Integer.toString(mCooldown)));
|
||||||
|
|
||||||
status.setVisibility(View.VISIBLE);
|
|
||||||
|
|
||||||
mCooldown--;
|
mCooldown--;
|
||||||
mHandler.removeMessages(MESSAGE_COOLDOWN);
|
mHandler.removeMessages(MESSAGE_COOLDOWN);
|
||||||
mHandler.sendEmptyMessageDelayed(MESSAGE_COOLDOWN, 1000); // Tick every second
|
mHandler.sendEmptyMessageDelayed(MESSAGE_COOLDOWN, 1000); // Tick every second
|
||||||
|
Reference in New Issue
Block a user