Rewriting phone constants for mainline

* Exposing Emergency extra constants through TelephonyManager
* Always reading or writing PhoneConstants.SubscriptionKey
with SubscriptionManager.EXTRA_SUBSCRIPTION_KEY

Bug: 147465477
Test: TeleServiceTests
Change-Id: I9cf495f19f3a752459ed67aa21bf6e0510a66547
diff --git a/src/com/android/phone/PhoneGlobals.java b/src/com/android/phone/PhoneGlobals.java
index b81e77f..7f1e60d 100644
--- a/src/com/android/phone/PhoneGlobals.java
+++ b/src/com/android/phone/PhoneGlobals.java
@@ -662,7 +662,8 @@
                     if (TelephonyCapabilities.supportsEcm(phoneInEcm)) {
                         Log.d(LOG_TAG, "Emergency Callback Mode arrived in PhoneApp.");
                         // Start Emergency Callback Mode service
-                        if (intent.getBooleanExtra("phoneinECMState", false)) {
+                        if (intent.getBooleanExtra(
+                                TelephonyManager.EXTRA_PHONE_IN_ECM_STATE, false)) {
                             context.startService(new Intent(context,
                                     EmergencyCallbackModeService.class));
                         } else {