am 242184ca: Merge "Allow tablets to send SMS if enabled in device overlays (1/2)"

* commit '242184ca23b8ef70f5347874ac9b5c59cce36208':
  Allow tablets to send SMS if enabled in device overlays (1/2)
This commit is contained in:
Wink Saville
2014-04-16 20:26:53 +00:00
committed by Android Git Automerger
2 changed files with 2 additions and 2 deletions

View File

@@ -64,7 +64,7 @@ public final class SmsDefaultDialog extends AlertActivity implements
private boolean buildDialog(String packageName) {
TelephonyManager tm = (TelephonyManager)getSystemService(Context.TELEPHONY_SERVICE);
if (tm.getPhoneType() == TelephonyManager.PHONE_TYPE_NONE) {
if (!tm.isSmsCapable()) {
// No phone, no SMS
return false;
}

View File

@@ -247,7 +247,7 @@ public class WirelessSettings extends RestrictedSettingsFragment
private boolean isSmsSupported() {
// Some tablet has sim card but could not do telephony operations. Skip those.
return (mTm.getPhoneType() != TelephonyManager.PHONE_TYPE_NONE);
return mTm.isSmsCapable();
}
@Override