summaryrefslogtreecommitdiff
path: root/core/java
diff options
context:
space:
mode:
authorSelim Cinek <cinek@google.com>2016-11-03 14:55:40 -0700
committerSelim Cinek <cinek@google.com>2016-11-14 23:00:24 +0000
commitb8a7f78d242cafb0c3ec10868c28583e8aacdf7a (patch)
treeb5db7a87eeafe101f3d740a7a871c0b017f4ebdd /core/java
parent0a2ac837d1ceb0bceb4c8448642dc9b59e39fa29 (diff)
Fixed a bug with the emergency affordance in multi user
The emergency call was not launched in the current user and therefore was only launching once the user had switched. Change-Id: If6f3bcf77d88a0658b6e0f91f7e4da5d6264b04f Fixes: 32424103 Test: manual: switch to secondary user and launch emergency affordance
Diffstat (limited to 'core/java')
-rw-r--r--core/java/com/android/internal/policy/EmergencyAffordanceManager.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/core/java/com/android/internal/policy/EmergencyAffordanceManager.java b/core/java/com/android/internal/policy/EmergencyAffordanceManager.java
index bed7c1ba4ed3..eb75bd497434 100644
--- a/core/java/com/android/internal/policy/EmergencyAffordanceManager.java
+++ b/core/java/com/android/internal/policy/EmergencyAffordanceManager.java
@@ -20,6 +20,7 @@ import android.content.Context;
import android.content.Intent;
import android.net.Uri;
import android.os.Build;
+import android.os.UserHandle;
import android.provider.Settings;
/**
@@ -72,7 +73,7 @@ public class EmergencyAffordanceManager {
Intent intent = new Intent(Intent.ACTION_CALL_EMERGENCY);
intent.setData(getPhoneUri(context));
intent.setFlags(Intent.FLAG_ACTIVITY_NEW_TASK);
- context.startActivity(intent);
+ context.startActivityAsUser(intent, UserHandle.CURRENT);
}
/**