Home
last modified time | relevance | path

Searched refs:ContactsPreferences (Results 1 – 25 of 33) sorted by relevance

12

/packages/apps/Contacts/tests/src/com/android/contacts/preference/
DContactsPreferencesTest.java46 private ContactsPreferences mContactsPreferences;
61 Mockito.when(mSharedPreferences.contains(ContactsPreferences.SORT_ORDER_KEY)) in setUp()
63 Mockito.when(mSharedPreferences.contains(ContactsPreferences.DISPLAY_ORDER_KEY)) in setUp()
65 Mockito.when(mSharedPreferences.contains(ContactsPreferences.PHONETIC_NAME_DISPLAY_KEY)) in setUp()
71 mContactsPreferences = new ContactsPreferences(mContext); in setUp()
81 Assert.assertEquals(ContactsPreferences.SORT_ORDER_PRIMARY, in testGetSortOrderDefault()
89 Mockito.when(mSharedPreferences.getInt(Mockito.eq(ContactsPreferences.SORT_ORDER_KEY), in testGetSortOrder()
90 Mockito.anyInt())).thenReturn(ContactsPreferences.SORT_ORDER_PRIMARY); in testGetSortOrder()
91 Assert.assertEquals(ContactsPreferences.SORT_ORDER_PRIMARY, in testGetSortOrder()
100 Assert.assertEquals(ContactsPreferences.DISPLAY_ORDER_PRIMARY, in testGetDisplayOrderDefault()
[all …]
/packages/apps/Contacts/tests/src/com/android/contacts/util/
DContactDisplayUtilTests.java25 import com.android.contacts.preference.ContactsPreferences;
40 @Mock private ContactsPreferences mContactsPreferences;
98 .thenReturn(ContactsPreferences.DISPLAY_ORDER_ALTERNATIVE); in testGetPreferredDisplayName_EmptyAlternative()
111 .thenReturn(ContactsPreferences.DISPLAY_ORDER_PRIMARY); in testGetPreferredDisplayName_Primary()
118 .thenReturn(ContactsPreferences.DISPLAY_ORDER_ALTERNATIVE); in testGetPreferredDisplayName_Alternative()
144 .thenReturn(ContactsPreferences.SORT_ORDER_ALTERNATIVE); in testGetPreferredSortName_EmptyAlternative()
157 .thenReturn(ContactsPreferences.SORT_ORDER_PRIMARY); in testGetPreferredSortName_Primary()
164 .thenReturn(ContactsPreferences.SORT_ORDER_ALTERNATIVE); in testGetPreferredSortName_Alternative()
/packages/apps/Contacts/src/com/android/contacts/preference/
DDisplayOrderPreference.java31 private ContactsPreferences mPreferences;
46 mPreferences = new ContactsPreferences(mContext); in prepare()
52 String.valueOf(ContactsPreferences.DISPLAY_ORDER_PRIMARY), in prepare()
53 String.valueOf(ContactsPreferences.DISPLAY_ORDER_ALTERNATIVE), in prepare()
66 case ContactsPreferences.DISPLAY_ORDER_PRIMARY: in getSummary()
68 case ContactsPreferences.DISPLAY_ORDER_ALTERNATIVE: in getSummary()
DSortOrderPreference.java31 private ContactsPreferences mPreferences;
46 mPreferences = new ContactsPreferences(mContext); in prepare()
52 String.valueOf(ContactsPreferences.SORT_ORDER_PRIMARY), in prepare()
53 String.valueOf(ContactsPreferences.SORT_ORDER_ALTERNATIVE), in prepare()
66 case ContactsPreferences.SORT_ORDER_PRIMARY: in getSummary()
68 case ContactsPreferences.SORT_ORDER_ALTERNATIVE: in getSummary()
DContactsPreferences.java42 public class ContactsPreferences implements OnSharedPreferenceChangeListener { class
92 public ContactsPreferences(Context context) { in ContactsPreferences() method in ContactsPreferences
98 ContactsPreferences(Context context, boolean isDefaultAccountUserChangeable) { in ContactsPreferences() method in ContactsPreferences
DPhoneticNameDisplayPreference.java35 private ContactsPreferences mPreferences;
49 mPreferences = new ContactsPreferences(mContext); in prepare()
DDefaultAccountPreference.java33 private ContactsPreferences mPreferences;
63 mPreferences = new ContactsPreferences(getContext()); in prepare()
DDisplayOptionsPreferenceFragment.java337 final ContactsPreferences contactsPrefs = new ContactsPreferences(context);
339 if (displayOrder == ContactsPreferences.DISPLAY_ORDER_PRIMARY) {
/packages/apps/Contacts/src/com/android/contacts/util/
DContactDisplayUtils.java30 import com.android.contacts.preference.ContactsPreferences;
213 @Nullable ContactsPreferences contactsPreferences) { in getPreferredDisplayName()
217 if (contactsPreferences.getDisplayOrder() == ContactsPreferences.DISPLAY_ORDER_PRIMARY) { in getPreferredDisplayName()
221 if (contactsPreferences.getDisplayOrder() == ContactsPreferences.DISPLAY_ORDER_ALTERNATIVE in getPreferredDisplayName()
240 @Nullable ContactsPreferences contactsPreferences) { in getPreferredSortName()
245 if (contactsPreferences.getSortOrder() == ContactsPreferences.SORT_ORDER_PRIMARY) { in getPreferredSortName()
249 if (contactsPreferences.getSortOrder() == ContactsPreferences.SORT_ORDER_ALTERNATIVE && in getPreferredSortName()
/packages/apps/Contacts/tests/src/com/android/contacts/list/
DContactListItemViewTest.java27 import com.android.contacts.preference.ContactsPreferences;
58 view.showDisplayName(cursor, 0, ContactsPreferences.DISPLAY_ORDER_PRIMARY); in testShowDisplayName_Simple()
68 view.showDisplayName(cursor, 0, ContactsPreferences.DISPLAY_ORDER_PRIMARY); in testShowDisplayName_Unknown()
78 view.showDisplayName(cursor, 0, ContactsPreferences.DISPLAY_ORDER_PRIMARY); in testShowDisplayName_WithPrefix()
93 view.showDisplayName(cursor, 0, ContactsPreferences.DISPLAY_ORDER_ALTERNATIVE); in testShowDisplayName_WithPrefixReversed()
/packages/apps/Contacts/tests/src/com/android/contacts/tests/
DAdbHelpers.java29 import com.android.contacts.preference.ContactsPreferences;
74 new ContactsPreferences(context).setDefaultAccount( in setDefaultAccount()
79 new ContactsPreferences(context).clearDefaultAccount(); in clearDefaultAccount()
/packages/apps/Contacts/src/com/android/contacts/editor/
DContactEditorUtils.java31 import com.android.contacts.preference.ContactsPreferences;
41 private final ContactsPreferences mContactsPrefs;
44 mContactsPrefs = new ContactsPreferences(context); in ContactEditorUtils()
DPickRawContactDialogFragment.java34 import com.android.contacts.preference.ContactsPreferences;
57 private final ContactsPreferences mPreferences;
64 mPreferences = new ContactsPreferences(context); in RawContactAccountListAdapter()
104 mPreferences.getDisplayOrder() == ContactsPreferences.DISPLAY_ORDER_PRIMARY in getView()
/packages/apps/Contacts/src/com/android/contacts/list/
DContactListAdapter.java33 import com.android.contacts.preference.ContactsPreferences;
401 if (sortOrder == ContactsPreferences.DISPLAY_ORDER_PRIMARY) { in getProjection()
407 if (sortOrder == ContactsPreferences.DISPLAY_ORDER_PRIMARY) { in getProjection()
421 if (sortOrder == ContactsPreferences.DISPLAY_ORDER_PRIMARY) { in getDataProjectionForContacts()
427 if (sortOrder == ContactsPreferences.DISPLAY_ORDER_PRIMARY) { in getDataProjectionForContacts()
DDefaultContactListAdapter.java35 import com.android.contacts.preference.ContactsPreferences;
101 if (getSortOrder() == ContactsPreferences.SORT_ORDER_PRIMARY) { in configureLoader()
268 return prefs.getBoolean(ContactsPreferences.PREF_DISPLAY_ONLY_PHONES, in isCustomFilterForPhoneNumbersOnly()
269 ContactsPreferences.PREF_DISPLAY_ONLY_PHONES_DEFAULT); in isCustomFilterForPhoneNumbersOnly()
DPostalAddressListAdapter.java31 import com.android.contacts.preference.ContactsPreferences;
85 if (getContactNameDisplayOrder() == ContactsPreferences.DISPLAY_ORDER_PRIMARY) { in configureLoader()
91 if (getSortOrder() == ContactsPreferences.SORT_ORDER_PRIMARY) { in configureLoader()
DEmailAddressListAdapter.java32 import com.android.contacts.preference.ContactsPreferences;
95 if (getContactNameDisplayOrder() == ContactsPreferences.DISPLAY_ORDER_PRIMARY) { in configureLoader()
101 if (getSortOrder() == ContactsPreferences.SORT_ORDER_PRIMARY) { in configureLoader()
DMultiSelectEmailAddressesListAdapter.java32 import com.android.contacts.preference.ContactsPreferences;
108 if (getContactNameDisplayOrder() == ContactsPreferences.DISPLAY_ORDER_PRIMARY) { in configureLoader()
114 if (getSortOrder() == ContactsPreferences.SORT_ORDER_PRIMARY) { in configureLoader()
DMultiSelectPhoneNumbersListAdapter.java32 import com.android.contacts.preference.ContactsPreferences;
108 if (getContactNameDisplayOrder() == ContactsPreferences.DISPLAY_ORDER_PRIMARY) { in configureLoader()
114 if (getSortOrder() == ContactsPreferences.SORT_ORDER_PRIMARY) { in configureLoader()
DContactEntryListFragment.java53 import com.android.contacts.preference.ContactsPreferences;
146 private ContactsPreferences mContactsPrefs;
284 mContactsPrefs = new ContactsPreferences(mContext); in onCreate()
955 private ContactsPreferences.ChangeListener mPreferencesChangeListener =
956 new ContactsPreferences.ChangeListener() {
DJoinContactListAdapter.java34 import com.android.contacts.preference.ContactsPreferences;
102 if (getSortOrder() == ContactsPreferences.SORT_ORDER_PRIMARY) { in configureLoader()
/packages/apps/Contacts/src/com/android/contacts/detail/
DContactDisplayUtils.java42 import com.android.contacts.preference.ContactsPreferences;
62 ContactsPreferences prefs = new ContactsPreferences(context); in getDisplayName()
64 if (prefs.getDisplayOrder() == ContactsPreferences.DISPLAY_ORDER_PRIMARY) { in getDisplayName()
/packages/apps/Contacts/src/com/android/contacts/group/
DGroupMembersAdapter.java33 import com.android.contacts.preference.ContactsPreferences;
123 getContactNameDisplayOrder() == ContactsPreferences.DISPLAY_ORDER_PRIMARY in configureLoader()
128 getSortOrder() == ContactsPreferences.SORT_ORDER_PRIMARY in configureLoader()
/packages/apps/Contacts/src/com/android/contacts/interactions/
DContactMultiDeletionInteraction.java39 import com.android.contacts.preference.ContactsPreferences;
205 final ContactsPreferences contactsPreferences = new ContactsPreferences(mContext); in onLoadFinished()
/packages/apps/Contacts/src/com/android/contacts/
DSimImportFragment.java52 import com.android.contacts.preference.ContactsPreferences;
79 private ContactsPreferences mPreferences;
101 mPreferences = new ContactsPreferences(getContext()); in onCreate()

12