Enable outgoing emergency calls in LockTask mode.
As part of the LockTask 2.0 work, we allow DPCs to enable the system lock
screen in LockTask mode. When the device is protected by a PIN, pattern, or
password, the lock screen will have an entry point to the emergency dialer
which allows the user to make emergency calls (e.g., 911).
Therefore, we whitelist the activities that are necessary to place this
outgoing emergency call when LOCK_TASK_FEATURE_KEYGUARD is enabled.
Bug: 68750910
Test: bit FrameworksServicesTests:com.android.server.am.LockTaskControllerTest
Test: CTS verifier > CTS verifier > Managed provisioning > Device owner tests
> LockTask UI
Change-Id: Iaeeec2c462b978d2d201c5660024a3dd7283ae07
diff --git a/telecomm/java/android/telecom/TelecomManager.java b/telecomm/java/android/telecom/TelecomManager.java
index 92d458f..6dcc3da 100644
--- a/telecomm/java/android/telecom/TelecomManager.java
+++ b/telecomm/java/android/telecom/TelecomManager.java
@@ -582,13 +582,21 @@
"android.telecom.extra.CALL_BACK_INTENT";
/**
+ * The dialer activity responsible for placing emergency calls from, for example, a locked
+ * keyguard.
+ * @hide
+ */
+ public static final ComponentName EMERGENCY_DIALER_COMPONENT =
+ ComponentName.createRelative("com.android.phone", ".EmergencyDialer");
+
+ /**
* The following 4 constants define how properties such as phone numbers and names are
* displayed to the user.
*/
/**
* Indicates that the address or number of a call is allowed to be displayed for caller ID.
- */
+ */
public static final int PRESENTATION_ALLOWED = 1;
/**