Merge "Hiding VideoCall button in call log when video is not available." into lmp-dev
diff --git a/src/com/android/dialer/calllog/CallLogAdapter.java b/src/com/android/dialer/calllog/CallLogAdapter.java
index e7d5a4a..d0c7632 100644
--- a/src/com/android/dialer/calllog/CallLogAdapter.java
+++ b/src/com/android/dialer/calllog/CallLogAdapter.java
@@ -41,6 +41,7 @@
import android.widget.Toast;
import com.android.common.widget.GroupingListAdapter;
+import com.android.contacts.common.CallUtil;
import com.android.contacts.common.ContactPhotoManager;
import com.android.contacts.common.ContactPhotoManager.DefaultImageRequest;
import com.android.contacts.common.util.UriUtils;
@@ -992,7 +993,8 @@
}
// If one of the calls had video capabilities, show the video call button.
- if (canPlaceCallToNumber && views.phoneCallDetailsViews.callTypeIcons.isVideoShown()) {
+ if (CallUtil.isVideoEnabled(mContext) && canPlaceCallToNumber &&
+ views.phoneCallDetailsViews.callTypeIcons.isVideoShown()) {
views.videoCallButtonView.setTag(
IntentProvider.getReturnVideoCallIntentProvider(views.number));
views.videoCallButtonView.setVisibility(View.VISIBLE);