diff options
author | Treehugger Robot <treehugger-gerrit@google.com> | 2018-04-11 21:22:26 +0000 |
---|---|---|
committer | Gerrit Code Review <noreply-gerritcodereview@google.com> | 2018-04-11 21:22:26 +0000 |
commit | d4d9fb5e6dcaa284c955d112f21cc420f0f7f3f2 (patch) | |
tree | 4d0aa7d6f8a6ded1f9c71f2165113988c8872469 /java/com/android/incallui | |
parent | 6e714e712a91f7eb3c12ed76ba2482e2714c2bc1 (diff) | |
parent | b175d252b8801c4219343d7bff1b76ca1f2eb030 (diff) |
Merge changes I6db36017,I0f0b44e5
* changes:
Add RTT badge to new call log.
Update logic for incoming and active calls.
Diffstat (limited to 'java/com/android/incallui')
-rw-r--r-- | java/com/android/incallui/AnswerScreenPresenter.java | 4 | ||||
-rw-r--r-- | java/com/android/incallui/InCallActivity.java | 8 |
2 files changed, 8 insertions, 4 deletions
diff --git a/java/com/android/incallui/AnswerScreenPresenter.java b/java/com/android/incallui/AnswerScreenPresenter.java index a0c76f345..0b79e4be7 100644 --- a/java/com/android/incallui/AnswerScreenPresenter.java +++ b/java/com/android/incallui/AnswerScreenPresenter.java @@ -140,7 +140,9 @@ public class AnswerScreenPresenter return; } incomingCall.setIsSpeakEasyCall(true); - incomingCall.answer(); + InCallActivity inCallActivity = + (InCallActivity) answerScreen.getAnswerScreenFragment().getActivity(); + inCallActivity.onPrimaryCallStateChanged(); } @Override diff --git a/java/com/android/incallui/InCallActivity.java b/java/com/android/incallui/InCallActivity.java index 8f0fbadff..0c57dff7b 100644 --- a/java/com/android/incallui/InCallActivity.java +++ b/java/com/android/incallui/InCallActivity.java @@ -1396,8 +1396,10 @@ public class InCallActivity extends TransactionSafeFragmentActivity return new ShouldShowUiResult(false, null); } - // TODO(erfanian): Get a better call? - DialerCall call = CallList.getInstance().getActiveCall(); + DialerCall call = + CallList.getInstance().getIncomingCall() != null + ? CallList.getInstance().getIncomingCall() + : CallList.getInstance().getActiveCall(); if (call == null) { return new ShouldShowUiResult(false, call); @@ -1417,7 +1419,7 @@ public class InCallActivity extends TransactionSafeFragmentActivity private ShouldShowUiResult getShouldShowAnswerUi() { DialerCall call = CallList.getInstance().getIncomingCall(); - if (call != null) { + if (call != null && !call.isSpeakEasyCall()) { LogUtil.i("InCallActivity.getShouldShowAnswerUi", "found incoming call"); return new ShouldShowUiResult(true, call); } |