diff --git a/res/layout-sw600dp/crypt_keeper_password_entry.xml b/res/layout-sw600dp/crypt_keeper_password_entry.xml index fe6edafd49e..f8c113d9209 100644 --- a/res/layout-sw600dp/crypt_keeper_password_entry.xml +++ b/res/layout-sw600dp/crypt_keeper_password_entry.xml @@ -16,7 +16,8 @@ ** limitations under the License. */ --> - @@ -25,7 +26,7 @@ - + diff --git a/res/layout/crypt_keeper_status.xml b/res/layout/crypt_keeper_status.xml index d94e66dc1d4..b92bbe80c57 100644 --- a/res/layout/crypt_keeper_status.xml +++ b/res/layout/crypt_keeper_status.xml @@ -23,6 +23,7 @@ android:orientation="vertical" android:layout_width="wrap_content" android:layout_height="wrap_content" + android:layout_gravity="center_horizontal" > diff --git a/src/com/android/settings/CryptKeeper.java b/src/com/android/settings/CryptKeeper.java index 3e88e27fe50..2739d9127a0 100644 --- a/src/com/android/settings/CryptKeeper.java +++ b/src/com/android/settings/CryptKeeper.java @@ -476,6 +476,16 @@ public class CryptKeeper extends Activity implements TextView.OnEditorActionList mPasswordEntry.setOnEditorActionListener(this); mPasswordEntry.requestFocus(); + // Disable the Emergency call button if the device has no voice telephone capability + final TelephonyManager tm = (TelephonyManager) getSystemService(Context.TELEPHONY_SERVICE); + if (!tm.isVoiceCapable()) { + final View emergencyCall = findViewById(R.id.emergencyCallButton); + if (emergencyCall != null) { + Log.d(TAG, "Removing the emergency Call button"); + emergencyCall.setVisibility(View.GONE); + } + } + final View imeSwitcher = findViewById(R.id.switch_ime_button); final InputMethodManager imm = (InputMethodManager) getSystemService( Context.INPUT_METHOD_SERVICE);