diff options
author | Santos Cordon <santoscordon@google.com> | 2014-08-14 01:53:44 -0700 |
---|---|---|
committer | Santos Cordon <santoscordon@google.com> | 2014-08-18 17:11:02 +0000 |
commit | e0ec555ed70bb58208eaa12b139d155ae0b20bdd (patch) | |
tree | 3f8297668f34e9f005c887f29a8abda11b7a4e31 | |
parent | 2a9bf823521974938d82179b750dd637523b6649 (diff) |
Fix parentID for conference call support.
Bug:16844332
Bug:16449372
Change-Id: I815df3aa8c2cf9db5dd20d670a64e3fd59493f56
-rw-r--r-- | InCallUI/src/com/android/incallui/Call.java | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/InCallUI/src/com/android/incallui/Call.java b/InCallUI/src/com/android/incallui/Call.java index 01f2e8b30..075ec981d 100644 --- a/InCallUI/src/com/android/incallui/Call.java +++ b/InCallUI/src/com/android/incallui/Call.java @@ -169,7 +169,6 @@ public final class Call { private final String mId; private int mState = State.INVALID; private int mDisconnectCause; - private String mParentCallId; private int mSessionModificationState; private final List<String> mChildCallIds = new ArrayList<>(); @@ -205,11 +204,6 @@ public final class Call { setState(translateState(mTelecommCall.getState())); setDisconnectCause(mTelecommCall.getDetails().getDisconnectCauseCode()); - if (mTelecommCall.getParent() != null) { - mParentCallId = CallList.getInstance().getCallByTelecommCall( - mTelecommCall.getParent()).getId(); - } - if (mTelecommCall.getVideoCall() != null) { if (mVideoCallListener == null) { mVideoCallListener = new InCallVideoCallListener(this); @@ -264,7 +258,7 @@ public final class Call { } public int getState() { - if (mParentCallId != null) { + if (mTelecommCall.getParent() != null) { return State.CONFERENCED; } else { return mState; @@ -343,7 +337,11 @@ public final class Call { } public String getParentId() { - return mParentCallId; + android.telecomm.Call parentCall = mTelecommCall.getParent(); + if (parentCall != null) { + return CallList.getInstance().getCallByTelecommCall(parentCall).getId(); + } + return null; } public int getVideoState() { @@ -385,7 +383,7 @@ public final class Call { State.toString(mState), PhoneCapabilities.toString(mTelecommCall.getDetails().getCallCapabilities()), mChildCallIds, - mParentCallId, + getParentId(), mTelecommCall.getDetails().getVideoState()); } } |