Add FLAG_RECEIVER_FOREGROUND to broadcast to call receiver.
Bug: 17692294
Change-Id: Ibe2b012a83b940735a11e4adccc3d7d8ec99e8ea
diff --git a/src/com/android/server/telecom/CallActivity.java b/src/com/android/server/telecom/CallActivity.java
index 69da7e4..07f66e4 100644
--- a/src/com/android/server/telecom/CallActivity.java
+++ b/src/com/android/server/telecom/CallActivity.java
@@ -156,8 +156,7 @@
*/
private boolean sendBroadcastToReceiver(Intent intent, boolean incoming) {
intent.putExtra(CallReceiver.KEY_IS_INCOMING_CALL, incoming);
- // Clear out any flags set previously since we don't need it for the broadcast.
- intent.setFlags(0);
+ intent.setFlags(Intent.FLAG_RECEIVER_FOREGROUND);
intent.setClass(this, CallReceiver.class);
Log.d(this, "Sending broadcast as user to CallReceiver- isIncoming: %s", incoming);
sendBroadcastAsUser(intent, UserHandle.OWNER);