Try BT audio connection one more time before failing
am: f789bc0180
Change-Id: Iff477a7dd1b5bf3c40de65871855535318a9b3e3
diff --git a/src/com/android/server/telecom/InCallController.java b/src/com/android/server/telecom/InCallController.java
index fde2910..cdda387 100644
--- a/src/com/android/server/telecom/InCallController.java
+++ b/src/com/android/server/telecom/InCallController.java
@@ -287,7 +287,7 @@
}
protected void onDisconnected() {
- InCallController.this.onDisconnected(mInCallServiceInfo.getComponentName());
+ InCallController.this.onDisconnected(mInCallServiceInfo);
disconnect(); // Unbind explicitly if we get disconnected.
if (mListener != null) {
mListener.onDisconnect(InCallServiceBindingConnection.this);
@@ -1026,6 +1026,7 @@
mNonUIInCallServiceConnections.disconnect();
mNonUIInCallServiceConnections = null;
}
+ mInCallServices.clear();
}
/**
@@ -1319,12 +1320,12 @@
/**
* Cleans up an instance of in-call app after the service has been unbound.
*
- * @param disconnectedComponent The {@link ComponentName} of the service which disconnected.
+ * @param disconnectedInfo The {@link InCallServiceInfo} of the service which disconnected.
*/
- private void onDisconnected(ComponentName disconnectedComponent) {
- Log.i(this, "onDisconnected from %s", disconnectedComponent);
+ private void onDisconnected(InCallServiceInfo disconnectedInfo) {
+ Log.i(this, "onDisconnected from %s", disconnectedInfo.getComponentName());
- mInCallServices.remove(disconnectedComponent);
+ mInCallServices.remove(disconnectedInfo);
}
/**
diff --git a/src/com/android/server/telecom/ui/MissedCallNotifierImpl.java b/src/com/android/server/telecom/ui/MissedCallNotifierImpl.java
index bbacd36..9851674 100644
--- a/src/com/android/server/telecom/ui/MissedCallNotifierImpl.java
+++ b/src/com/android/server/telecom/ui/MissedCallNotifierImpl.java
@@ -309,6 +309,7 @@
publicBuilder.setSmallIcon(android.R.drawable.stat_notify_missed_call)
.setColor(mContext.getResources().getColor(R.color.theme_color))
.setWhen(callInfo.getCreationTimeMillis())
+ .setShowWhen(true)
// Show "Phone" for notification title.
.setContentTitle(mContext.getText(R.string.userCallActivityLabel))
// Notification details shows that there are missed call(s), but does not reveal
@@ -323,6 +324,7 @@
builder.setSmallIcon(android.R.drawable.stat_notify_missed_call)
.setColor(mContext.getResources().getColor(R.color.theme_color))
.setWhen(callInfo.getCreationTimeMillis())
+ .setShowWhen(true)
.setContentTitle(mContext.getText(titleResId))
.setContentText(expandedText)
.setContentIntent(createCallLogPendingIntent(userHandle))
diff --git a/tests/Android.mk b/tests/Android.mk
index 212bbd7..77abcad 100644
--- a/tests/Android.mk
+++ b/tests/Android.mk
@@ -23,8 +23,7 @@
android-support-test \
guava \
mockito-target \
- platform-test-annotations \
- legacy-android-test
+ platform-test-annotations
LOCAL_SRC_FILES := \
$(call all-java-files-under, src) \
@@ -41,7 +40,8 @@
$(SUPPORT_LIBRARY_ROOT)/compat/res
LOCAL_JAVA_LIBRARIES := \
- android.test.runner \
+ android.test.mock \
+ legacy-android-test \
telephony-common
LOCAL_AAPT_FLAGS := \