summaryrefslogtreecommitdiffstats
path: root/telecomm/java/android/telecom/Call.java
diff options
context:
space:
mode:
Diffstat (limited to 'telecomm/java/android/telecom/Call.java')
-rw-r--r--telecomm/java/android/telecom/Call.java47
1 files changed, 35 insertions, 12 deletions
diff --git a/telecomm/java/android/telecom/Call.java b/telecomm/java/android/telecom/Call.java
index 6fa653d..ba0aaf3 100644
--- a/telecomm/java/android/telecom/Call.java
+++ b/telecomm/java/android/telecom/Call.java
@@ -156,7 +156,7 @@ public final class Call {
* Local device supports bidirectional video calling.
* @hide
*/
- public static final int CAPABILITY_SUPPORTS_VT_LOCAL =
+ public static final int CAPABILITY_SUPPORTS_VT_LOCAL_BIDIRECTIONAL =
CAPABILITY_SUPPORTS_VT_LOCAL_RX | CAPABILITY_SUPPORTS_VT_LOCAL_TX;
/**
@@ -175,7 +175,7 @@ public final class Call {
* Remote device supports bidirectional video calling.
* @hide
*/
- public static final int CAPABILITY_SUPPORTS_VT_REMOTE =
+ public static final int CAPABILITY_SUPPORTS_VT_REMOTE_BIDIRECTIONAL =
CAPABILITY_SUPPORTS_VT_REMOTE_RX | CAPABILITY_SUPPORTS_VT_REMOTE_TX;
/**
@@ -221,8 +221,14 @@ public final class Call {
*/
public static final int CAPABILITY_SPEED_UP_MT_AUDIO = 0x00040000;
- //**********************************************************************************************
- // Next CAPABILITY value: 0x00080000
+ /**
+ * Call type can be modified for IMS call
+ * @hide
+ */
+ public static final int CAPABILITY_CAN_UPGRADE_TO_VIDEO = 0x00080000;
+
+ //******************************************************************************************
+ // Next CAPABILITY value: 0x00100000
//******************************************************************************************
private final Uri mHandle;
@@ -238,6 +244,7 @@ public final class Call {
private final int mVideoState;
private final StatusHints mStatusHints;
private final Bundle mExtras;
+ private final int mCallSubstate;
/**
* Whether the supplied capabilities supports the specified capability.
@@ -298,8 +305,8 @@ public final class Call {
if (can(capabilities, CAPABILITY_SUPPORTS_VT_LOCAL_TX)) {
builder.append(" CAPABILITY_SUPPORTS_VT_LOCAL_TX");
}
- if (can(capabilities, CAPABILITY_SUPPORTS_VT_LOCAL)) {
- builder.append(" CAPABILITY_SUPPORTS_VT_LOCAL");
+ if (can(capabilities, CAPABILITY_SUPPORTS_VT_LOCAL_BIDIRECTIONAL)) {
+ builder.append(" CAPABILITY_SUPPORTS_VT_LOCAL_BIDIRECTIONAL");
}
if (can(capabilities, CAPABILITY_SUPPORTS_VT_REMOTE_RX)) {
builder.append(" CAPABILITY_SUPPORTS_VT_REMOTE_RX");
@@ -307,8 +314,8 @@ public final class Call {
if (can(capabilities, CAPABILITY_SUPPORTS_VT_REMOTE_TX)) {
builder.append(" CAPABILITY_SUPPORTS_VT_REMOTE_TX");
}
- if (can(capabilities, CAPABILITY_SUPPORTS_VT_REMOTE)) {
- builder.append(" CAPABILITY_SUPPORTS_VT_REMOTE");
+ if (can(capabilities, CAPABILITY_SUPPORTS_VT_REMOTE_BIDIRECTIONAL)) {
+ builder.append(" CAPABILITY_SUPPORTS_VT_REMOTE_BIDIRECTIONAL");
}
if (can(capabilities, CAPABILITY_HIGH_DEF_AUDIO)) {
builder.append(" CAPABILITY_HIGH_DEF_AUDIO");
@@ -325,6 +332,9 @@ public final class Call {
if (can(capabilities, CAPABILITY_SPEED_UP_MT_AUDIO)) {
builder.append(" CAPABILITY_SPEED_UP_MT_AUDIO");
}
+ if (can(capabilities, CAPABILITY_CAN_UPGRADE_TO_VIDEO)) {
+ builder.append(" CAPABILITY_CAN_UPGRADE_TO_VIDEO");
+ }
builder.append("]");
return builder.toString();
}
@@ -430,6 +440,14 @@ public final class Call {
return mExtras;
}
+ /**
+ * @return The substate of the {@code Call}.
+ * @hide
+ */
+ public int getCallSubstate() {
+ return mCallSubstate;
+ }
+
@Override
public boolean equals(Object o) {
if (o instanceof Details) {
@@ -448,7 +466,8 @@ public final class Call {
Objects.equals(mGatewayInfo, d.mGatewayInfo) &&
Objects.equals(mVideoState, d.mVideoState) &&
Objects.equals(mStatusHints, d.mStatusHints) &&
- Objects.equals(mExtras, d.mExtras);
+ Objects.equals(mExtras, d.mExtras) &&
+ Objects.equals(mCallSubstate, d.mCallSubstate);
}
return false;
}
@@ -468,7 +487,8 @@ public final class Call {
Objects.hashCode(mGatewayInfo) +
Objects.hashCode(mVideoState) +
Objects.hashCode(mStatusHints) +
- Objects.hashCode(mExtras);
+ Objects.hashCode(mExtras) +
+ Objects.hashCode(mCallSubstate);
}
/** {@hide} */
@@ -485,7 +505,8 @@ public final class Call {
GatewayInfo gatewayInfo,
int videoState,
StatusHints statusHints,
- Bundle extras) {
+ Bundle extras,
+ int callSubstate) {
mHandle = handle;
mHandlePresentation = handlePresentation;
mCallerDisplayName = callerDisplayName;
@@ -499,6 +520,7 @@ public final class Call {
mVideoState = videoState;
mStatusHints = statusHints;
mExtras = extras;
+ mCallSubstate = callSubstate;
}
}
@@ -879,7 +901,8 @@ public final class Call {
parcelableCall.getGatewayInfo(),
parcelableCall.getVideoState(),
parcelableCall.getStatusHints(),
- parcelableCall.getExtras());
+ parcelableCall.getExtras(),
+ parcelableCall.getCallSubstate());
boolean detailsChanged = !Objects.equals(mDetails, details);
if (detailsChanged) {
mDetails = details;