Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 03b86310 authored by Sean Midford's avatar Sean Midford Committed by Android (Google) Code Review
Browse files

Merge "Revert "Fixed quick contact button in send to labels"" into ub-contactsdialer-h-dev

parents c2f3fe2b 06ec1b14
Loading
Loading
Loading
Loading
+3 −13
Original line number Diff line number Diff line
@@ -29,7 +29,6 @@ import android.view.ViewGroup;

import android.provider.ContactsContract.CommonDataKinds.Email;

import com.android.contacts.common.ContactPhotoManager;
import com.android.contacts.common.list.ContactListItemView;
import com.android.contacts.common.list.MultiSelectEntryContactListAdapter;
import com.android.contacts.common.preference.ContactsPreferences;
@@ -163,7 +162,9 @@ public class MultiSelectEmailAddressesListAdapter extends MultiSelectEntryContac
        bindViewId(view, cursor, EmailQuery.EMAIL_ID);
        if (isFirstEntry) {
            bindName(view, cursor);
            bindPhoto(view, cursor);
            bindQuickContact(view, partition, cursor, EmailQuery.PHOTO_ID,
                    EmailQuery.PHOTO_URI, EmailQuery.CONTACT_ID,
                    EmailQuery.LOOKUP_KEY, EmailQuery.DISPLAY_NAME);
        } else {
            unbindName(view);
            view.removePhotoView(true, false);
@@ -171,17 +172,6 @@ public class MultiSelectEmailAddressesListAdapter extends MultiSelectEntryContac
        bindEmailAddress(view, cursor);
    }

    protected void bindPhoto(final ContactListItemView view, Cursor cursor) {
        final long photoId = cursor.isNull(EmailQuery.PHOTO_ID)
                ? 0 : cursor.getLong(EmailQuery.PHOTO_ID);
        final ContactPhotoManager.DefaultImageRequest imageRequest = photoId == 0
                ? getDefaultImageRequestFromCursor(cursor, EmailQuery.DISPLAY_NAME,
                EmailQuery.LOOKUP_KEY)
                : null;
        getPhotoLoader().loadThumbnail(view.getPhotoView(), photoId, false, getCircularPhotos(),
                imageRequest);
    }

    protected void unbindName(final ContactListItemView view) {
        view.hideDisplayName();
    }
+3 −13
Original line number Diff line number Diff line
@@ -29,7 +29,6 @@ import android.view.ViewGroup;

import android.provider.ContactsContract.CommonDataKinds.Phone;

import com.android.contacts.common.ContactPhotoManager;
import com.android.contacts.common.list.ContactListItemView;
import com.android.contacts.common.list.MultiSelectEntryContactListAdapter;
import com.android.contacts.common.preference.ContactsPreferences;
@@ -163,7 +162,9 @@ public class MultiSelectPhoneNumbersListAdapter extends MultiSelectEntryContactL
        bindViewId(view, cursor, PhoneQuery.PHONE_ID);
        if (isFirstEntry) {
            bindName(view, cursor);
            bindPhoto(view, cursor);
            bindQuickContact(view, partition, cursor, PhoneQuery.PHOTO_ID,
                        PhoneQuery.PHOTO_URI, PhoneQuery.CONTACT_ID,
                        PhoneQuery.LOOKUP_KEY, PhoneQuery.DISPLAY_NAME);
        } else {
            unbindName(view);
            view.removePhotoView(true, false);
@@ -171,17 +172,6 @@ public class MultiSelectPhoneNumbersListAdapter extends MultiSelectEntryContactL
        bindPhoneNumber(view, cursor);
    }

    protected void bindPhoto(final ContactListItemView view, Cursor cursor) {
        final long photoId = cursor.isNull(PhoneQuery.PHOTO_ID)
                ? 0 : cursor.getLong(PhoneQuery.PHOTO_ID);
        final ContactPhotoManager.DefaultImageRequest imageRequest = photoId == 0
                ? getDefaultImageRequestFromCursor(cursor, PhoneQuery.DISPLAY_NAME,
                PhoneQuery.LOOKUP_KEY)
                : null;
        getPhotoLoader().loadThumbnail(view.getPhotoView(), photoId, false, getCircularPhotos(),
                imageRequest);
    }

    protected void unbindName(final ContactListItemView view) {
        view.hideDisplayName();
    }