ECBM SystemProperty cleanup
- Add getEmergencyCallbackMode() method to get the boolean
value for ECBM callback mode from the phone, in the
PhoneInterfaceManager.java
- Replace the 'get' of PROPERTY_INECM_MODE system property
in the packages/services/Telephony
Change-Id: Ide35e28b3339f58523bfe92be3c2fdfce111d45e
Test: Manual
Bug: 30361624
diff --git a/src/com/android/phone/PhoneInterfaceManager.java b/src/com/android/phone/PhoneInterfaceManager.java
index 52c2a79..3f61b34 100644
--- a/src/com/android/phone/PhoneInterfaceManager.java
+++ b/src/com/android/phone/PhoneInterfaceManager.java
@@ -3807,4 +3807,18 @@
phone.setSimPowerState(powerUp);
}
}
+
+ /**
+ * Check if phone is in emergency callback mode
+ * @return true if phone is in emergency callback mode
+ * @param subId sub id
+ */
+ public boolean getEmergencyCallbackMode(int subId) {
+ final Phone phone = getPhone(subId);
+ if (phone != null) {
+ return phone.isInEcm();
+ } else {
+ return false;
+ }
+ }
}