summaryrefslogtreecommitdiff
path: root/java
diff options
context:
space:
mode:
authoryueg <yueg@google.com>2017-09-18 15:11:47 -0700
committerEric Erfanian <erfanian@google.com>2017-09-18 15:48:36 -0700
commit457b39781aa4ce65fc3846bd895c215fc60fc29d (patch)
tree4e27e310bc3136c7a80a19ea489af0671164c088 /java
parent5287a2335195f80b6e1dcd702ce9ab101118ec95 (diff)
Log if a call is IMS reachable.
And fix a related test in ImsVideoTechTest. LOG_STORAGE_INCREASE(GB/week): 0.7 5M active block user/day * 10 events/active = 350M event/wk 350M event/wk * (2 [bool])/event = 0.7GB/wk Test: LoggerUtilsTest PiperOrigin-RevId: 169153878 Change-Id: Ia8038a5b0961f1a5572541f21df7a2680d85bbbb
Diffstat (limited to 'java')
-rw-r--r--java/com/android/incallui/call/DialerCall.java16
1 files changed, 15 insertions, 1 deletions
diff --git a/java/com/android/incallui/call/DialerCall.java b/java/com/android/incallui/call/DialerCall.java
index 9f8992575..ee9a92609 100644
--- a/java/com/android/incallui/call/DialerCall.java
+++ b/java/com/android/incallui/call/DialerCall.java
@@ -153,6 +153,8 @@ public class DialerCall implements VideoTechListener, StateChangedListener, Capa
private int secondCallWithoutAnswerAndReleasedButtonTimes = 0;
private VideoTech videoTech;
+ private boolean isImsReachable;
+
public static String getNumberFromHandle(Uri handle) {
return handle == null ? "" : handle.getSchemeSpecificPart();
}
@@ -1297,6 +1299,14 @@ public class DialerCall implements VideoTechListener, StateChangedListener, Capa
mVideoTechManager.dispatchRemovedFromCallList();
}
+ public boolean isImsReachable() {
+ return isImsReachable;
+ }
+
+ private void setImsReachable(boolean imsReachable) {
+ isImsReachable = imsReachable;
+ }
+
/**
* Specifies whether a number is in the call history or not. {@link #CALL_HISTORY_STATUS_UNKNOWN}
* means there is no result.
@@ -1502,7 +1512,11 @@ public class DialerCall implements VideoTechListener, StateChangedListener, Capa
// Insert order here determines the priority of that video tech option
videoTechs = new ArrayList<>();
- videoTechs.add(new ImsVideoTech(Logger.get(call.mContext), call, call.mTelecomCall));
+
+ ImsVideoTech imsVideoTech =
+ new ImsVideoTech(Logger.get(call.mContext), call, call.mTelecomCall);
+ call.setImsReachable(imsVideoTech.isAvailable(context));
+ videoTechs.add(imsVideoTech);
VideoTech rcsVideoTech =
EnrichedCallComponent.get(call.mContext)