/packages/apps/Contacts/tests/src/com/android/contacts/widget/ |
D | CompositeListAdapterTest.java | 114 CompositeListAdapter adapter = new CompositeListAdapter(); in testGetCount() local 115 adapter.addAdapter(mAdapter1); in testGetCount() 116 adapter.addAdapter(mAdapter2); in testGetCount() 117 adapter.addAdapter(mAdapter3); in testGetCount() 119 assertEquals(5, adapter.getCount()); in testGetCount() 123 CompositeListAdapter adapter = new CompositeListAdapter(); in testGetCountWithInvalidation() local 124 assertEquals(0, adapter.getCount()); in testGetCountWithInvalidation() 126 adapter.addAdapter(mAdapter1); in testGetCountWithInvalidation() 127 assertEquals(2, adapter.getCount()); in testGetCountWithInvalidation() 129 adapter.addAdapter(mAdapter2); in testGetCountWithInvalidation() [all …]
|
/packages/apps/UnifiedEmail/src/com/android/mail/ui/ |
D | SeparatedFolderListAdapter.java | 33 public void addSection(FolderSelectorAdapter adapter) { in addSection() argument 34 mSections.add(adapter); in addSection() 43 for (FolderSelectorAdapter adapter : mSections) { in getItem() 44 int size = adapter.getCount(); in getItem() 48 return adapter.getItem(position); in getItem() 60 for (FolderSelectorAdapter adapter : mSections) { in getCount() 61 total += adapter.getCount(); in getCount() 70 for (Adapter adapter : mSections) in getViewTypeCount() 71 total += adapter.getViewTypeCount(); in getViewTypeCount() 78 for (FolderSelectorAdapter adapter : mSections) { in getItemViewType() [all …]
|
D | SwipeableListView.java | 220 final AnimatedAdapter adapter = getAnimatedAdapter(); in commitDestructiveActions() local 221 if (adapter != null) { in commitDestructiveActions() 222 adapter.commitLeaveBehindItems(animate); in commitDestructiveActions() 238 final AnimatedAdapter adapter = getAnimatedAdapter(); in dismissChild() local 239 if (adapter == null) { in dismissChild() 242 adapter.setupLeaveBehind(conv, undoOp, conv.position, target.getHeight()); in dismissChild() 243 ConversationCursor cc = (ConversationCursor) adapter.getCursor(); in dismissChild() 275 adapter.notifyDataSetChanged(); in dismissChild() 302 final AnimatedAdapter adapter = getAnimatedAdapter(); in onDragCancelled() local 303 if (adapter != null) { in onDragCancelled() [all …]
|
/packages/apps/Contacts/src/com/android/contacts/list/ |
D | PhoneNumberPickerFragment.java | 176 final PhoneNumberListAdapter adapter = (PhoneNumberListAdapter) getAdapter(); in getPhoneNumber() local 177 return adapter.getPhoneNumber(position); in getPhoneNumber() 181 final PhoneNumberListAdapter adapter = (PhoneNumberListAdapter) getAdapter(); in getPhoneUri() local 182 return adapter.getDataUri(position); in getPhoneUri() 186 final PhoneNumberListAdapter adapter = (PhoneNumberListAdapter) getAdapter(); in getLookupKey() local 187 return adapter.getLookupKey(position); in getLookupKey() 214 PhoneNumberListAdapter adapter = new PhoneNumberListAdapter(getActivity()); in createListAdapter() local 215 adapter.setDisplayPhotos(true); in createListAdapter() 216 adapter.setUseCallableUri(mUseCallableUri); in createListAdapter() 217 return adapter; in createListAdapter() [all …]
|
D | PostalAddressPickerFragment.java | 50 PostalAddressListAdapter adapter = (PostalAddressListAdapter)getAdapter(); in onItemClick() local 51 pickPostalAddress(adapter.getDataUri(position)); in onItemClick() 53 LegacyPostalAddressListAdapter adapter = (LegacyPostalAddressListAdapter)getAdapter(); in onItemClick() local 54 pickPostalAddress(adapter.getContactMethodUri(position)); in onItemClick() 61 PostalAddressListAdapter adapter = new PostalAddressListAdapter(getActivity()); in createListAdapter() local 62 adapter.setSectionHeaderDisplayEnabled(true); in createListAdapter() 63 adapter.setDisplayPhotos(true); in createListAdapter() 64 return adapter; in createListAdapter() 66 LegacyPostalAddressListAdapter adapter = in createListAdapter() local 68 adapter.setSectionHeaderDisplayEnabled(false); in createListAdapter() [all …]
|
D | ContactBrowseListFragment.java | 337 ContactListAdapter adapter = getAdapter(); in setSelectedContactUri() local 338 if (adapter != null) { in setSelectedContactUri() 339 adapter.setSelectedContact(mSelectedContactDirectoryId, in setSelectedContactUri() 388 ContactListAdapter adapter = getAdapter(); in configureAdapter() local 389 if (adapter == null) { in configureAdapter() 395 adapter.setFilter(mFilter); in configureAdapter() 398 adapter.setSelectedContact( in configureAdapter() 403 adapter.setIncludeFavorites(!searchMode && mFilter.isContactsFilterType()); in configureAdapter() 432 ContactListAdapter adapter = getAdapter(); in checkSelection() local 433 if (adapter == null) { in checkSelection() [all …]
|
D | ContactPickerFragment.java | 136 HeaderEntryContactListAdapter adapter in createListAdapter() local 138 adapter.setFilter(ContactListFilter.createFilterWithType( in createListAdapter() 140 adapter.setSectionHeaderDisplayEnabled(true); in createListAdapter() 141 adapter.setDisplayPhotos(true); in createListAdapter() 142 adapter.setQuickContactEnabled(false); in createListAdapter() 143 adapter.setShowCreateContact(mCreateContactEnabled); in createListAdapter() 144 return adapter; in createListAdapter() 146 LegacyContactListAdapter adapter = new LegacyContactListAdapter(getActivity()); in createListAdapter() local 147 adapter.setSectionHeaderDisplayEnabled(false); in createListAdapter() 148 adapter.setDisplayPhotos(false); in createListAdapter() [all …]
|
D | JoinContactListFragment.java | 63 JoinContactListAdapter adapter = getAdapter(); 64 if (adapter != null) { 65 adapter.configureLoader(loader, 0); 125 JoinContactListAdapter adapter = getAdapter(); in onContactListLoaded() local 126 adapter.setSuggestionsCursor(suggestionsCursor); in onContactListLoaded() 146 JoinContactListAdapter adapter = new JoinContactListAdapter(getActivity()); in createListAdapter() local 147 adapter.setPhotoPosition(ContactListItemView.getDefaultPhotoPosition(false /* opposite */)); in createListAdapter() 148 return adapter; in createListAdapter() 154 JoinContactListAdapter adapter = getAdapter(); in configureAdapter() local 155 adapter.setTargetContactId(mTargetContactId); in configureAdapter()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/applications/ |
D | ManageApplicationsTest.java | 118 final ManageApplications.ApplicationsAdapter adapter = in updateDisableView_appDisabledUntilUsed_shouldSetDisabled() local 121 adapter.updateDisableView(view, info); in updateDisableView_appDisabledUntilUsed_shouldSetDisabled() 171 final ManageApplications.ApplicationsAdapter adapter = in updateLoading_appLoaded_shouldNotDelayCallToHandleLoadingContainer() local 175 ReflectionHelpers.setField(adapter, "mLoadingViewController", loadingViewController); in updateLoading_appLoaded_shouldNotDelayCallToHandleLoadingContainer() 176 ReflectionHelpers.setField(adapter, "mFgHandler", handler); in updateLoading_appLoaded_shouldNotDelayCallToHandleLoadingContainer() 179 ReflectionHelpers.setField(adapter, "mHasReceivedLoadEntries", true); in updateLoading_appLoaded_shouldNotDelayCallToHandleLoadingContainer() 184 adapter.updateLoading(); in updateLoading_appLoaded_shouldNotDelayCallToHandleLoadingContainer() 197 final ManageApplications.ApplicationsAdapter adapter = in updateLoading_appNotLoaded_shouldDelayCallToHandleLoadingContainer() local 201 ReflectionHelpers.setField(adapter, "mLoadingViewController", loadingViewController); in updateLoading_appNotLoaded_shouldDelayCallToHandleLoadingContainer() 202 ReflectionHelpers.setField(adapter, "mFgHandler", handler); in updateLoading_appNotLoaded_shouldDelayCallToHandleLoadingContainer() [all …]
|
/packages/apps/UnifiedEmail/src/com/android/mail/browse/ |
D | MergedAdapter.java | 43 public LocalAdapterPosition(T adapter, int offset) { in LocalAdapterPosition() argument 44 mAdapter = adapter; in LocalAdapterPosition() 68 for (T adapter : mAdapters) { in setAdapters() 69 adapter.unregisterDataSetObserver(mObserver); in setAdapters() 75 for (T adapter : mAdapters) { in setAdapters() 76 adapter.registerDataSetObserver(mObserver); in setAdapters() 91 for (T adapter : mAdapters) { in getCount() 92 count += adapter.getCount(); in getCount() 140 for (T adapter : mAdapters) { in getViewTypeCount() 141 count += adapter.getViewTypeCount(); in getViewTypeCount() [all …]
|
/packages/apps/Gallery2/src/com/android/photos/views/ |
D | HeaderGridView.java | 81 ListAdapter adapter = getAdapter(); in onMeasure() local 82 if (adapter != null && adapter instanceof HeaderViewGridAdapter) { in onMeasure() 83 ((HeaderViewGridAdapter) adapter).setNumColumns(getNumColumns()); in onMeasure() 105 ListAdapter adapter = getAdapter(); in addHeaderView() local 107 if (adapter != null && ! (adapter instanceof HeaderViewGridAdapter)) { in addHeaderView() 123 if (adapter != null) { in addHeaderView() 124 ((HeaderViewGridAdapter) adapter).notifyDataSetChanged(); in addHeaderView() 156 ListAdapter adapter = getAdapter(); in removeHeaderView() local 157 if (adapter != null && ((HeaderViewGridAdapter) adapter).removeHeader(v)) { in removeHeaderView() 178 public void setAdapter(ListAdapter adapter) { in setAdapter() argument [all …]
|
/packages/apps/Car/libs/car-stream-ui-lib/src/com/android/car/app/ |
D | CarDrawerActivity.java | 103 private void setToolbarTitleFrom(CarDrawerAdapter adapter) { in setToolbarTitleFrom() argument 104 if (adapter.getTitle() != null) { in setToolbarTitleFrom() 105 mToolbar.setTitle(adapter.getTitle()); in setToolbarTitleFrom() 110 adapter.setTitleChangeListener(mToolbar::setTitle); in setToolbarTitleFrom() 149 public final void switchToAdapter(CarDrawerAdapter adapter) { in switchToAdapter() argument 151 mAdapterStack.push(adapter); in switchToAdapter() 152 setTitleAndSwitchToAdapter(adapter); in switchToAdapter() 281 private void setTitleAndSwitchToAdapter(CarDrawerAdapter adapter) { in setTitleAndSwitchToAdapter() argument 282 setToolbarTitleFrom(adapter); in setTitleAndSwitchToAdapter() 285 mDrawerList.getRecyclerView().setAdapter(adapter); in setTitleAndSwitchToAdapter() [all …]
|
/packages/apps/Tag/canon/src/com/android/apps/tagcanon/ |
D | TagCanon.java | 133 ArrayAdapter<TagDescription> adapter = new ArrayAdapter<TagDescription>(this, in onCreate() local 135 adapter.add(new TagDescription("Image", buildImageMessages())); in onCreate() 136 adapter.add(new TagDescription("Real NFC message", MockNdefMessages.REAL_NFC_MSG)); in onCreate() 137 adapter.add(new TagDescription("Call Google", MockNdefMessages.CALL_GOOGLE)); in onCreate() 138 adapter.add(new TagDescription("English text", MockNdefMessages.ENGLISH_PLAIN_TEXT)); in onCreate() 139 adapter.add(new TagDescription("Send text message", MockNdefMessages.SEND_TEXT_MESSAGE)); in onCreate() 140 …adapter.add(new TagDescription("SmartPoster URL & text", MockNdefMessages.SMART_POSTER_URL_AND_TEX… in onCreate() 141 … adapter.add(new TagDescription("SmartPoster URL", MockNdefMessages.SMART_POSTER_URL_NO_TEXT)); in onCreate() 142 adapter.add(new TagDescription("VCARD", MockNdefMessages.VCARD)); in onCreate() 143 adapter.add(new TagDescription("URI", MockNdefMessages.URI)); in onCreate() [all …]
|
/packages/apps/Dialer/java/com/android/dialer/app/list/ |
D | SearchFragment.java | 206 DialerPhoneNumberListAdapter adapter = new DialerPhoneNumberListAdapter(getActivity()); in createListAdapter() local 207 adapter.setDisplayPhotos(true); in createListAdapter() 208 adapter.setUseCallableUri(super.usesCallableUri()); in createListAdapter() 209 adapter.setListener(this); in createListAdapter() 210 return adapter; in createListAdapter() 215 final DialerPhoneNumberListAdapter adapter = (DialerPhoneNumberListAdapter) getAdapter(); in onItemClick() local 216 final int shortcutType = adapter.getShortcutTypeFromPosition(position); in onItemClick() 225 number = adapter.getQueryString(); in onItemClick() 245 ? adapter.getFormattedQueryString() in onItemClick() 257 ? adapter.getFormattedQueryString() in onItemClick() [all …]
|
D | SmartDialSearchFragment.java | 58 SmartDialNumberListAdapter adapter = new SmartDialNumberListAdapter(getActivity()); in createListAdapter() local 59 adapter.setUseCallableUri(super.usesCallableUri()); in createListAdapter() 60 adapter.setQuickContactEnabled(true); in createListAdapter() 61 adapter.setShowEmptyListForNullQuery(getShowEmptyListForNullQuery()); in createListAdapter() 63 adapter.setQueryString(getQueryString()); in createListAdapter() 64 adapter.setListener(this); in createListAdapter() 65 return adapter; in createListAdapter() 75 final SmartDialNumberListAdapter adapter = (SmartDialNumberListAdapter) getAdapter(); in onCreateLoader() local 78 adapter.configureLoader(loader); in onCreateLoader()
|
D | BlockedListSearchFragment.java | 124 BlockedListSearchAdapter adapter = new BlockedListSearchAdapter(getActivity()); in createListAdapter() local 125 adapter.setDisplayPhotos(true); in createListAdapter() 127 adapter.setUseCallableUri(false); in createListAdapter() 129 adapter.setQueryString(getQueryString() == null ? "" : getQueryString()); in createListAdapter() 130 return adapter; in createListAdapter() 137 final BlockedListSearchAdapter adapter = (BlockedListSearchAdapter) getAdapter(); in onItemClick() local 138 final int shortcutType = adapter.getShortcutTypeFromPosition(adapterPosition); in onItemClick() 144 number = adapter.getPhoneNumber(adapterPosition); in onItemClick() 149 number = adapter.getQueryString(); in onItemClick()
|
/packages/apps/Dialer/java/com/android/dialer/searchfragment/list/ |
D | NewSearchFragment.java | 46 private SearchAdapter adapter; field in NewSearchFragment 58 adapter = new SearchAdapter(getContext()); in onCreateView() 61 recyclerView.setAdapter(adapter); in onCreateView() 83 adapter.setContactsCursor(cursor); in onLoadFinished() 85 adapter.setNearbyPlacesCursor(cursor); in onLoadFinished() 93 adapter.clear(); in onLoaderReset() 99 if (adapter != null) { in setQuery() 100 adapter.setQuery(query); in setQuery() 109 adapter.setNearbyPlacesCursor(null); in onDestroy() 110 adapter.setContactsCursor(null); in onDestroy()
|
/packages/apps/Settings/tests/robotests/src/com/android/settings/dashboard/ |
D | DashboardAdapterTest.java | 419 final DashboardAdapter adapter = in testSuggestionDismissed_notOnlySuggestion_updateSuggestionOnly() local 422 adapter.setCategoriesAndSuggestions(null /* category */, suggestions); in testSuggestionDismissed_notOnlySuggestion_updateSuggestionOnly() 433 adapter.onBindConditionAndSuggestion( in testSuggestionDismissed_notOnlySuggestion_updateSuggestionOnly() 436 final DashboardData dashboardData = adapter.mDashboardData; in testSuggestionDismissed_notOnlySuggestion_updateSuggestionOnly() 437 reset(adapter); // clear interactions tracking in testSuggestionDismissed_notOnlySuggestion_updateSuggestionOnly() 440 adapter.onSuggestionDismissed(suggestionToRemove); in testSuggestionDismissed_notOnlySuggestion_updateSuggestionOnly() 442 assertThat(adapter.mDashboardData).isEqualTo(dashboardData); in testSuggestionDismissed_notOnlySuggestion_updateSuggestionOnly() 445 verify(adapter, never()).notifyDashboardDataChanged(any()); in testSuggestionDismissed_notOnlySuggestion_updateSuggestionOnly() 457 final DashboardAdapter adapter = spy(new DashboardAdapter(mContext, null /*savedInstance */, in testSuggestionDismissed_moreThanTwoSuggestions_defaultMode_shouldNotCrash() local 459 adapter.setCategoriesAndSuggestions(null /* category */, suggestions); in testSuggestionDismissed_moreThanTwoSuggestions_defaultMode_shouldNotCrash() [all …]
|
/packages/apps/TV/src/com/android/tv/dvr/ui/browse/ |
D | DvrBrowseFragment.java | 418 for (RecordedProgramAdapter adapter in handleRecordedProgramAdded() 420 adapter.add(recordedProgram); in handleRecordedProgramAdded() 439 for (RecordedProgramAdapter adapter in handleRecordedProgramRemoved() 441 adapter.remove(recordedProgram); in handleRecordedProgramRemoved() 477 for (RecordedProgramAdapter adapter in handleSeriesRecordingsAdded() 479 adapter.add(seriesRecording); in handleSeriesRecordingsAdded() 488 for (RecordedProgramAdapter adapter in handleSeriesRecordingsRemoved() 490 adapter.remove(seriesRecording); in handleSeriesRecordingsRemoved() 542 for (RecordedProgramAdapter adapter : mGenreAdapters) { in updateGenreAdapters() 543 if (adapters.contains(adapter)) { in updateGenreAdapters() [all …]
|
/packages/apps/Launcher3/src/com/android/launcher3/allapps/ |
D | AllAppsRecyclerView.java | 154 public void preMeasureViews(AllAppsGridAdapter adapter) { in preMeasureViews() argument 155 View icon = adapter.onCreateViewHolder(this, AllAppsGridAdapter.VIEW_TYPE_ICON).itemView; in preMeasureViews() 165 putSameHeightFor(adapter, widthMeasureSpec, heightMeasureSpec, in preMeasureViews() 168 putSameHeightFor(adapter, widthMeasureSpec, heightMeasureSpec, in preMeasureViews() 170 putSameHeightFor(adapter, widthMeasureSpec, heightMeasureSpec, in preMeasureViews() 174 putSameHeightFor(adapter, widthMeasureSpec, heightMeasureSpec, in preMeasureViews() 176 putSameHeightFor(adapter, widthMeasureSpec, heightMeasureSpec, in preMeasureViews() 181 private void putSameHeightFor(AllAppsGridAdapter adapter, int w, int h, int... viewTypes) { in putSameHeightFor() argument 182 View view = adapter.onCreateViewHolder(this, viewTypes[0]).itemView; in putSameHeightFor() 332 public void setAdapter(Adapter adapter) { in setAdapter() argument [all …]
|
/packages/apps/Dialer/java/com/android/contacts/common/list/ |
D | PhoneNumberPickerFragment.java | 262 final PhoneNumberListAdapter adapter = (PhoneNumberListAdapter) getAdapter(); in getPhoneNumber() local 263 return adapter.getPhoneNumber(position); in getPhoneNumber() 267 final PhoneNumberListAdapter adapter = (PhoneNumberListAdapter) getAdapter(); in getLookupKey() local 268 return adapter.getLookupKey(position); in getLookupKey() 382 PhoneNumberListAdapter adapter = new PhoneNumberListAdapter(getActivity()); in createListAdapter() local 383 adapter.setDisplayPhotos(true); in createListAdapter() 384 adapter.setUseCallableUri(mUseCallableUri); in createListAdapter() 385 return adapter; in createListAdapter() 392 final ContactEntryListAdapter adapter = getAdapter(); in configureAdapter() local 393 if (adapter == null) { in configureAdapter() [all …]
|
/packages/apps/Contacts/src/com/android/contacts/interactions/ |
D | ImportDialogFragment.java | 131 final ArrayAdapter<AdapterEntry> adapter = new ArrayAdapter<AdapterEntry>(getActivity(), in onCreateDialog() local 185 addItems(adapter); in onCreateDialog() 191 final int resId = adapter.getItem(which).mChoiceResourceId; in onCreateDialog() 193 handleSimImportRequest(adapter.getItem(which).mSim); in onCreateDialog() 207 if (adapter.isEmpty()) { in onCreateDialog() 211 builder.setSingleChoiceItems(adapter, -1, clickListener); in onCreateDialog() 228 private void addItems(ArrayAdapter<AdapterEntry> adapter) { in addItems() argument 231 adapter.add(new AdapterEntry(getString(R.string.import_from_vcf_file), in addItems() 237 adapter.add(new AdapterEntry(getString(R.string.import_from_sim), in addItems() 243 adapter.add(new AdapterEntry(getSimDescription(sim, i), R.string.import_from_sim, sim)); in addItems()
|
/packages/apps/Settings/src/com/android/settings/datetime/ |
D | ZonePicker.java | 96 final SimpleAdapter adapter = new SimpleAdapter(context, in constructTimezoneAdapter() local 101 adapter.setViewBinder(new TimeZoneViewBinder()); in constructTimezoneAdapter() 102 return adapter; in constructTimezoneAdapter() 130 public static int getTimeZoneIndex(SimpleAdapter adapter, TimeZone tz) { in getTimeZoneIndex() argument 132 final int listSize = adapter.getCount(); in getTimeZoneIndex() 135 final HashMap<?,?> map = (HashMap<?,?>)adapter.getItem(i); in getTimeZoneIndex() 228 final SimpleAdapter adapter = in setSorting() local 230 setListAdapter(adapter); in setSorting() 232 final int defaultIndex = getTimeZoneIndex(adapter, TimeZone.getDefault()); in setSorting()
|
/packages/apps/Dialer/java/com/android/dialer/contactsfragment/ |
D | ContactsFragment.java | 62 private ContactsAdapter adapter; field in ContactsFragment 129 adapter = new ContactsAdapter(getContext(), cursor); in onLoadFinished() 136 if (adapter.getItemCount() > itemsShown) { in onLoadFinished() 146 recyclerView.setAdapter(adapter); in onLoadFinished() 148 fastScroller.setup(adapter, manager); in onLoadFinished() 156 adapter = null; in onLoaderReset() 179 String anchoredHeaderString = adapter.getHeaderString(firstCompletelyVisible); in onScrollChange() 185 adapter.refreshHeaders(); in onScrollChange() 188 if (adapter.getHeaderString(firstVisibleItem).equals(anchoredHeaderString)) { in onScrollChange()
|
/packages/apps/Dialer/java/com/android/incallui/incall/impl/ |
D | InCallFragment.java | 80 private InCallPagerAdapter adapter; field in InCallFragment 98 pager.setCurrentItem(adapter.getButtonGridPosition()); 266 if (adapter == null) { in setAdapterMedia() 267 adapter = new InCallPagerAdapter(getChildFragmentManager(), multimediaData); in setAdapterMedia() 268 pager.setAdapter(adapter); in setAdapterMedia() 270 adapter.setAttachments(multimediaData); in setAdapterMedia() 273 if (adapter.getCount() > 1 && getResources().getInteger(R.integer.incall_num_rows) > 1) { in setAdapterMedia() 280 pager.setCurrentItem(adapter.getButtonGridPosition(), false /* animateScroll */); in setAdapterMedia() 450 if (adapter != null in updateButtonStates() 451 && adapter.getCount() > 1 in updateButtonStates() [all …]
|