Home
last modified time | relevance | path

Searched refs:getItemCount (Results 1 – 25 of 123) sorted by relevance

12345

/frameworks/support/v7/recyclerview/src/android/support/v7/widget/
DScrollbarHelper.java32 if (lm.getChildCount() == 0 || state.getItemCount() == 0 || startChild == null || in computeScrollOffset()
41 ? Math.max(0, state.getItemCount() - maxPosition - 1) in computeScrollOffset()
63 if (lm.getChildCount() == 0 || state.getItemCount() == 0 || startChild == null || in computeScrollExtent()
82 if (lm.getChildCount() == 0 || state.getItemCount() == 0 || startChild == null || in computeScrollRange()
87 return state.getItemCount(); in computeScrollRange()
96 return (int) ((float) laidOutArea / laidOutRange * state.getItemCount()); in computeScrollRange()
DLayoutState.java90 return mCurrentPosition >= 0 && mCurrentPosition < state.getItemCount(); in hasMore()
/frameworks/base/packages/DocumentsUI/tests/src/com/android/documentsui/dirlist/
DSectionBreakDocumentsAdapterWrapperTest.java82 assertEquals(mModel.getItemCount(), mAdapter.getItemCount()); in testItemCount_allDirs()
88 assertEquals(mModel.getItemCount(), mAdapter.getItemCount()); in testItemCount_allFiles()
108 assertEquals(mModel.getItemCount() + 1, mAdapter.getItemCount()); in testItemCount_mixed()
161 public int getItemCount() { return 0; } in getItemCount() method in SectionBreakDocumentsAdapterWrapperTest.DummyAdapter
DModelBackedDocumentsAdapterTest.java66 assertEquals(mModel.getItemCount(), mAdapter.getItemCount()); in testItemCount()
73 assertEquals(mModel.getItemCount() - 2, mAdapter.getItemCount()); in testHide_ItemCount()
126 public int getItemCount() { return 0; } in getItemCount() method in ModelBackedDocumentsAdapterTest.DummyAdapter
DTestDocumentsAdapter.java74 public int getItemCount() { in getItemCount() method in TestDocumentsAdapter
/frameworks/support/v7/recyclerview/tests/src/android/support/v7/widget/
DGridLayoutManagerBaseConfigSetTest.java56 for (int i = 1; i < mAdapter.getItemCount(); i += config.mSpanCount + 2) { in scrollBackAndPreservePositionsTest()
60 final int[] globalPositions = new int[mAdapter.getItemCount()]; in scrollBackAndPreservePositionsTest()
72 while (visited < mAdapter.getItemCount()) { in scrollBackAndPreservePositionsTest()
99 visited, mAdapter.getItemCount()); in scrollBackAndPreservePositionsTest()
116 expectedPositions.set(mAdapter.getItemCount() - i - 1); in scrollBackAndPreservePositionsTest()
131 BitSet shouldTest = new BitSet(mAdapter.getItemCount()); in scrollBackAndPreservePositionsTest()
132 shouldTest.set(0, mAdapter.getItemCount() - 1, true); in scrollBackAndPreservePositionsTest()
DLinearLayoutManagerSavedStateTest.java99 scrollToPosition(testAdapter().getItemCount() * 3 / 4); in params()
112 scrollToPositionWithOffset(testAdapter().getItemCount() / 3, in params()
126 scrollToPositionWithOffset(testAdapter().getItemCount() * 2 / 3, in params()
218 position = testAdapter().getItemCount() / 2; in params()
224 return testAdapter().getItemCount() == 0; in params()
234 if (testAdapter().getItemCount() > 0) { in params()
295 final int itemCount = mTestAdapter.getItemCount(); in savedStateTest()
DStaggeredGridLayoutManagerSavedStateTest.java77 scrollToPosition(adapter().getItemCount() * 3 / 4); in getParams()
90 scrollToPositionWithOffset(adapter().getItemCount() / 3, in getParams()
104 scrollToPositionWithOffset(adapter().getItemCount() * 2 / 3, in getParams()
181 final int itemCount = mAdapter.getItemCount(); in savedState()
DRecyclerViewAccessibilityTest.java157 assertEquals(adapter.getItemCount(), collectionInfo.getRowCount()); in onInitializeAccessibilityNodeInfoTest()
160 assertEquals(adapter.getItemCount(), collectionInfo.getColumnCount()); in onInitializeAccessibilityNodeInfoTest()
174 assertEquals(record.getItemCount(), adapter.getItemCount()); in onInitializeAccessibilityNodeInfoTest()
DRecyclerViewCacheTest.java112 when(mockAdapter.getItemCount()).thenReturn(10); in prefetchReusesCacheItems()
175 when(mockAdapter.getItemCount()).thenReturn(100); in prefetchItemsNotEvictedWithInserts()
225 when(mockAdapter.getItemCount()).thenReturn(100); in prefetchItemsNotEvictedOnScroll()
272 public int getItemCount() { return 10; } in prefetchItemsSkipAnimations()
DLinearLayoutManagerBaseConfigSetTest.java79 scrollToPositionWithOffset(mTestAdapter.getItemCount() - 1, in scrollToPositionWithOffsetTest()
186 final int scrollPosition = config.mStackFromEnd ? 0 : mTestAdapter.getItemCount(); in getFirstLastChildrenTest()
200 mTestAdapter.deleteAndNotify(0, mTestAdapter.getItemCount()); in getFirstLastChildrenTest()
310 (mRecyclerView.getAdapter().getItemCount() - maxPosition) / 2; in findInvisibleTarget()
DRecyclerViewLayoutTest.java551 public int getItemCount() { in requestRectOnScreenWithScrollOffset()
584 layoutRange(recycler, 0, Math.min(state.getItemCount(), 10)); in reattachAndScrollCrash()
591 for (int i = 10; i < state.getItemCount(); i++) { in reattachAndScrollCrash()
611 adapter.deleteAndNotify(1, adapter.getItemCount() - 1); in reattachAndScrollCrash()
716 recycler.getViewForPosition(state.getItemCount() - 1); in testFocusSearchAfterChangedData()
1558 layoutRange(recycler, 0, state.getItemCount()); in adapterPositionInvalidation()
1664 layoutRange(recycler, 0, state.getItemCount()); in avoidLeakingRecyclerViewIfViewIsNotRecycled()
1719 layoutRange(recycler, 0, state.getItemCount()); in avoidLeakingRecyclerViewViaViewHolder()
1753 layoutRange(recycler, 0, state.getItemCount()); in duplicateAdapterPositionTest()
1893 layoutRange(recycler, Math.min(state.getItemCount(), 2) in adapterPositionsTest()
[all …]
/frameworks/base/packages/DocumentsUI/src/com/android/documentsui/dirlist/
DFocusManager.java123 if (mAdapter.getItemCount() == 0) { in restoreLastFocus()
157 return mAdapter.getItemCount() - 1; in findTargetPosition()
186 if (currentPosition < mAdapter.getItemCount() - 1) { in findTargetPosition()
254 int max = mAdapter.getItemCount() - 1; in findPagedTargetPosition()
476 int itemCount = mAdapter.getItemCount(); in buildIndex()
DSectionBreakDocumentsAdapterWrapper.java98 public int getItemCount() {
100 ? mDelegate.getItemCount()
101 : mDelegate.getItemCount() + 1;
/frameworks/support/samples/Support7Demos/src/com/example/android/supportv7/widget/
DRecyclerViewActivity.java63 if (pos + 1 < getItemCount()) { in onCreate()
123 final int count = state.getItemCount(); in onLayoutChildren()
182 if (scrolled < dy && state.getItemCount() > mFirstPosition + getChildCount()) { in scrollVerticallyBy()
228 while (mFirstPosition + getChildCount() < state.getItemCount() && in onFocusSearchFailed()
DBaseLayoutManagerActivity.java92 if (pos != RecyclerView.NO_POSITION && pos + 1 < getItemCount()) { in createAdapter()
136 return mRecyclerView.getAdapter().getItemCount();
190 public int getItemCount() {
DAsyncListUtilActivity.java105 public int getItemCount() { in getItemCount() method in AsyncListUtilActivity.AsyncAdapter
106 return mAsyncListUtil.getItemCount(); in getItemCount()
DNestedRecyclerViewActivity.java81 public int getItemCount() { in getItemCount() method in NestedRecyclerViewActivity.InnerAdapter
128 public int getItemCount() { in getItemCount() method in NestedRecyclerViewActivity.OuterAdapter
/frameworks/opt/setupwizard/library/full-support/src/com/android/setupwizardlib/view/
DHeaderRecyclerView.java156 public int getItemCount() { in getItemCount() method in HeaderRecyclerView.HeaderAdapter
157 int count = mAdapter.getItemCount(); in getItemCount()
217 event.setItemCount(event.getItemCount() - numberOfHeaders); in onInitializeAccessibilityEvent()
/frameworks/data-binding/samples/BindingDemo/app/src/main/java/com/android/example/bindingdemo/
DMainActivity.java92 dataBinder.robotList.smoothScrollToPosition(robotAdapter.getItemCount() - 1); in onDelete()
95 dataBinder.toolkittyList.smoothScrollToPosition(tkAdapter.getItemCount() - 1); in onDelete()
158 public int getItemCount() { in getItemCount() method in MainActivity.UserAdapter
/frameworks/base/services/core/java/com/android/server/clipboard/
DClipboardService.java162 if (clip != null && clip.getItemCount() <= 0) { in setPrimaryClip()
196 for (int i = clip.getItemCount() - 1; i >= 0; i--) { in setPrimaryClip()
343 final int N = data.getItemCount(); in checkDataOwnerLocked()
392 final int N = clipboard.primaryClip.getItemCount(); in addActiveOwnerLocked()
429 final int N = clipboard.primaryClip.getItemCount(); in revokeUris()
/frameworks/support/compat/java/android/support/v4/view/accessibility/
DAccessibilityRecordCompat.java50 public int getItemCount(Object record); in getItemCount() method
124 public int getItemCount(Object record) { in getItemCount() method in AccessibilityRecordCompat.AccessibilityRecordStubImpl
356 public int getItemCount(Object record) { in getItemCount() method in AccessibilityRecordCompat.AccessibilityRecordIcsImpl
357 return AccessibilityRecordCompatIcs.getItemCount(record); in getItemCount()
770 public int getItemCount() { in getItemCount() method in AccessibilityRecordCompat
771 return IMPL.getItemCount(mRecord); in getItemCount()
/frameworks/base/packages/DocumentsUI/src/com/android/documentsui/
DDocumentClipper.java59 int count = clipData.getItemCount(); in hasItemsToPaste()
94 int count = clipData.getItemCount(); in getDocumentsFromClipData()
/frameworks/base/services/tests/servicestests/src/com/android/server/
DMockAccessibilityService.java201 TestCase.assertEquals("itemCount has incorrect value", expectedEvent.getItemCount(), in assertEqualsAccessiblityEvent()
202 receivedEvent.getItemCount()); in assertEqualsAccessiblityEvent()
/frameworks/support/compat/ics/android/support/v4/view/accessibility/
DAccessibilityRecordCompatIcs.java62 public static int getItemCount(Object record) { in getItemCount() method in AccessibilityRecordCompatIcs
63 return ((AccessibilityRecord) record).getItemCount(); in getItemCount()

12345