diff options
Diffstat (limited to 'InCallUI')
-rw-r--r-- | InCallUI/res/layout/secondary_call_info.xml | 7 | ||||
-rw-r--r-- | InCallUI/src/com/android/incallui/CallCardFragment.java | 6 | ||||
-rw-r--r-- | InCallUI/src/com/android/incallui/CallCardPresenter.java | 14 |
3 files changed, 21 insertions, 6 deletions
diff --git a/InCallUI/res/layout/secondary_call_info.xml b/InCallUI/res/layout/secondary_call_info.xml index 85eef0ee1..e866795a6 100644 --- a/InCallUI/res/layout/secondary_call_info.xml +++ b/InCallUI/res/layout/secondary_call_info.xml @@ -40,6 +40,13 @@ android:paddingBottom="@dimen/secondary_call_info_vertical_padding" android:background="?android:attr/selectableItemBackground"> + <ImageView android:id="@+id/secondaryCallVideoCallIcon" + android:layout_width="wrap_content" + android:layout_height="wrap_content" + android:src="@drawable/ic_toolbar_video" + android:tint="@color/incall_banner_secondary_text_color" + android:paddingEnd="16dp"/> + <ImageView android:id="@+id/secondaryCallConferenceCallIcon" android:layout_width="wrap_content" android:layout_height="wrap_content" diff --git a/InCallUI/src/com/android/incallui/CallCardFragment.java b/InCallUI/src/com/android/incallui/CallCardFragment.java index 9f43502e0..805ff0c6b 100644 --- a/InCallUI/src/com/android/incallui/CallCardFragment.java +++ b/InCallUI/src/com/android/incallui/CallCardFragment.java @@ -97,6 +97,7 @@ public class CallCardFragment extends BaseFragment<CallCardPresenter, CallCardPr private View mSecondaryCallProviderInfo; private TextView mSecondaryCallProviderLabel; private View mSecondaryCallConferenceCallIcon; + private View mSecondaryCallVideoCallIcon; private View mProgressSpinner; private View mManageConferenceCallButton; @@ -451,7 +452,7 @@ public class CallCardFragment extends BaseFragment<CallCardPresenter, CallCardPr @Override public void setSecondary(boolean show, String name, boolean nameIsNumber, String label, - String providerLabel, boolean isConference) { + String providerLabel, boolean isConference, boolean isVideoCall) { if (show != mSecondaryCallInfo.isShown()) { updateFabPositionForSecondaryCallInfo(); @@ -462,6 +463,7 @@ public class CallCardFragment extends BaseFragment<CallCardPresenter, CallCardPr showAndInitializeSecondaryCallInfo(hasProvider); mSecondaryCallConferenceCallIcon.setVisibility(isConference ? View.VISIBLE : View.GONE); + mSecondaryCallVideoCallIcon.setVisibility(isVideoCall ? View.VISIBLE : View.GONE); mSecondaryCallName.setText(nameIsNumber ? PhoneNumberUtils.ttsSpanAsPhoneNumber(name) @@ -749,6 +751,8 @@ public class CallCardFragment extends BaseFragment<CallCardPresenter, CallCardPr mSecondaryCallName = (TextView) getView().findViewById(R.id.secondaryCallName); mSecondaryCallConferenceCallIcon = getView().findViewById(R.id.secondaryCallConferenceCallIcon); + mSecondaryCallVideoCallIcon = + getView().findViewById(R.id.secondaryCallVideoCallIcon); } if (mSecondaryCallProviderLabel == null && hasProvider) { diff --git a/InCallUI/src/com/android/incallui/CallCardPresenter.java b/InCallUI/src/com/android/incallui/CallCardPresenter.java index 7eae5c602..401187a83 100644 --- a/InCallUI/src/com/android/incallui/CallCardPresenter.java +++ b/InCallUI/src/com/android/incallui/CallCardPresenter.java @@ -525,7 +525,8 @@ public class CallCardPresenter extends Presenter<CallCardPresenter.CallCardUi> if (mSecondary == null) { // Clear the secondary display info. - ui.setSecondary(false, null, false, null, null, false /* isConference */); + ui.setSecondary(false, null, false, null, null, false /* isConference */, + false /* isVideoCall */); return; } @@ -536,7 +537,8 @@ public class CallCardPresenter extends Presenter<CallCardPresenter.CallCardUi> false /* nameIsNumber */, null /* label */, getCallProviderLabel(mSecondary), - true /* isConference */); + true /* isConference */, + mSecondary.isVideoCall(mContext)); } else if (mSecondaryContactInfo != null) { Log.d(TAG, "updateSecondaryDisplayInfo() " + mSecondaryContactInfo); String name = getNameForCall(mSecondaryContactInfo); @@ -547,10 +549,12 @@ public class CallCardPresenter extends Presenter<CallCardPresenter.CallCardUi> nameIsNumber, mSecondaryContactInfo.label, getCallProviderLabel(mSecondary), - false /* isConference */); + false /* isConference */, + mSecondary.isVideoCall(mContext)); } else { // Clear the secondary display info. - ui.setSecondary(false, null, false, null, null, false /* isConference */); + ui.setSecondary(false, null, false, null, null, false /* isConference */, + false /* isVideoCall */); } } @@ -735,7 +739,7 @@ public class CallCardPresenter extends Presenter<CallCardPresenter.CallCardUi> void setPrimary(String number, String name, boolean nameIsNumber, String label, Drawable photo, boolean isSipCall); void setSecondary(boolean show, String name, boolean nameIsNumber, String label, - String providerLabel, boolean isConference); + String providerLabel, boolean isConference, boolean isVideoCall); void setCallState(int state, int videoState, int sessionModificationState, DisconnectCause disconnectCause, String connectionLabel, Drawable connectionIcon, String gatewayNumber, boolean isWifi); |