Home
last modified time | relevance | path

Searched refs:targetPosition (Results 1 – 19 of 19) sorted by relevance

/frameworks/base/core/tests/coretests/src/android/widget/listview/touch/
DListSetSelectionTest.java64 final int targetPosition = mListView.getAdapter().getCount() / 2; in testSetSelection() local
68 mListView.setSelection(targetPosition); in testSetSelection()
77 if (child.getId() == targetPosition) { in testSetSelection()
94 final int targetPosition = mListView.getAdapter().getCount() / 2; in testSetSelectionFromTop() local
98 mListView.setSelectionFromTop(targetPosition, 100); in testSetSelectionFromTop()
108 if (child.getId() == targetPosition) { in testSetSelectionFromTop()
/frameworks/base/core/tests/coretests/src/android/widget/gridview/touch/
DGridTouchSetSelectionTest.java62 final int targetPosition = mGridView.getAdapter().getCount() / 2; in testSetSelection() local
66 mGridView.setSelection(targetPosition); in testSetSelection()
75 if (child.getId() == targetPosition) { in testSetSelection()
/frameworks/support/room/integration-tests/testapp/src/main/java/androidx/room/integration/testapp/
DRoomPagedListActivity.java84 final int targetPosition = layoutManager.findFirstVisibleItemPosition(); in onSaveInstanceState() local
87 Customer customer = list.get(targetPosition); in onSaveInstanceState()
96 int absolutePosition = targetPosition + list.getPositionOffset(); in onSaveInstanceState()
/frameworks/support/v7/recyclerview/src/main/java/androidx/recyclerview/widget/
DSnapHelper.java166 int targetPosition = findTargetSnapPosition(layoutManager, velocityX, velocityY); in snapFromFling() local
167 if (targetPosition == RecyclerView.NO_POSITION) { in snapFromFling()
171 smoothScroller.setTargetPosition(targetPosition); in snapFromFling()
DLinearLayoutManager.java455 public PointF computeScrollVectorForPosition(int targetPosition) { in computeScrollVectorForPosition() argument
460 final int direction = targetPosition < firstChildPos != mShouldReverseLayout ? -1 : 1; in computeScrollVectorForPosition()
DRecyclerView.java11500 public void setTargetPosition(int targetPosition) { in setTargetPosition() argument
11501 mTargetPosition = targetPosition; in setTargetPosition()
11515 public PointF computeScrollVectorForPosition(int targetPosition) { in computeScrollVectorForPosition() argument
11519 .computeScrollVectorForPosition(targetPosition); in computeScrollVectorForPosition()
11801 public void jumpTo(int targetPosition) { in jumpTo() argument
11802 mJumpToPosition = targetPosition; in jumpTo()
11936 PointF computeScrollVectorForPosition(int targetPosition); in computeScrollVectorForPosition() argument
DStaggeredGridLayoutManager.java2053 public PointF computeScrollVectorForPosition(int targetPosition) {
2054 final int direction = calculateScrollDirectionForPosition(targetPosition);
/frameworks/base/core/java/com/android/internal/widget/
DLinearSmoothScroller.java351 public PointF computeScrollVectorForPosition(int targetPosition) { in computeScrollVectorForPosition() argument
355 .computeScrollVectorForPosition(targetPosition); in computeScrollVectorForPosition()
DLinearLayoutManager.java443 public PointF computeScrollVectorForPosition(int targetPosition) { in computeScrollVectorForPosition() argument
448 final int direction = targetPosition < firstChildPos != mShouldReverseLayout ? -1 : 1; in computeScrollVectorForPosition()
DRecyclerView.java10643 public void setTargetPosition(int targetPosition) { in setTargetPosition() argument
10644 mTargetPosition = targetPosition; in setTargetPosition()
10896 public void jumpTo(int targetPosition) { in jumpTo() argument
10897 mJumpToPosition = targetPosition; in jumpTo()
11026 PointF computeScrollVectorForPosition(int targetPosition); in computeScrollVectorForPosition() argument
/frameworks/base/services/core/java/com/android/server/wm/
DTaskStack.java620 final int targetPosition = findPositionForTask(child, position, showForAllUsers, in positionChildAt() local
622 super.positionChildAt(targetPosition, child, includingParents); in positionChildAt()
628 final int toTop = targetPosition == mChildren.size() - 1 ? 1 : 0; in positionChildAt()
629 EventLog.writeEvent(EventLogTags.WM_TASK_MOVED, child.mTaskId, toTop, targetPosition); in positionChildAt()
634 private int findPositionForTask(Task task, int targetPosition, boolean showForAllUsers, in findPositionForTask() argument
650 if (targetPosition == POSITION_BOTTOM && minPosition == 0) { in findPositionForTask()
652 } else if (targetPosition == POSITION_TOP in findPositionForTask()
657 return Math.min(Math.max(targetPosition, minPosition), maxPosition); in findPositionForTask()
DDisplayContent.java3413 final int targetPosition = findPositionForStack(position, child, false /* adding */); in positionChildAt() local
3414 super.positionChildAt(targetPosition, child, includingParents); in positionChildAt()
3432 int targetPosition = requestedPosition; in findPositionForStack() local
3446 targetPosition = adding ? topChildPosition : topChildPosition - 1; in findPositionForStack()
3449 return targetPosition; in findPositionForStack()
/frameworks/base/core/java/android/widget/
DGallery.java1294 int targetPosition = mSelectedPosition + direction; in moveDirection() local
1296 if (mItemCount > 0 && targetPosition >= 0 && targetPosition < mItemCount) { in moveDirection()
1297 scrollToChild(targetPosition - mFirstPosition); in moveDirection()
DSwitch.java1046 final float targetPosition = newCheckedState ? 1 : 0; in animateThumbToCheckedState() local
1047 mPositionAnimator = ObjectAnimator.ofFloat(this, THUMB_POS, targetPosition); in animateThumbToCheckedState()
/frameworks/support/v7/recyclerview/src/androidTest/java/androidx/recyclerview/widget/
DLinearLayoutManagerTest.java1017 final int targetPosition; in keepFocusOnResizeTest() local
1019 targetPosition = mLayoutManager.findFirstVisibleItemPosition(); in keepFocusOnResizeTest()
1021 targetPosition = mLayoutManager.findLastVisibleItemPosition(); in keepFocusOnResizeTest()
1025 .findViewHolderForLayoutPosition(targetPosition); in keepFocusOnResizeTest()
1085 .findViewHolderForLayoutPosition(targetPosition); in keepFocusOnResizeTest()
DRecyclerViewLayoutTest.java2965 public PointF computeScrollVectorForPosition(int targetPosition) { in smoothScrollTest()
2994 final int targetPosition = visibleChildCount * (removeItem ? 30 : 4); in smoothScrollTest() local
2998 rv.smoothScrollToPosition(targetPosition); in smoothScrollTest()
3002 Log.d(TAG, "scrolling to target position " + targetPosition); in smoothScrollTest()
3006 final int newTarget = targetPosition - 10; in smoothScrollTest()
3040 rv.findViewHolderForLayoutPosition(targetPosition)); in smoothScrollTest()
3161 public PointF computeScrollVectorForPosition(int targetPosition) { in smoothScrollToPosition_initialScroll()
4958 public PointF computeScrollVectorForPosition(int targetPosition) {
5066 public PointF computeScrollVectorForPosition(int targetPosition) {
/frameworks/support/v7/appcompat/src/main/java/androidx/appcompat/widget/
DSwitchCompat.java1021 final float targetPosition = newCheckedState ? 1 : 0; in animateThumbToCheckedState() local
1022 mPositionAnimator = ObjectAnimator.ofFloat(this, THUMB_POS, targetPosition); in animateThumbToCheckedState()
/frameworks/support/leanback/src/main/java/androidx/leanback/widget/
DGridLayoutManager.java369 public PointF computeScrollVectorForPosition(int targetPosition) { in computeScrollVectorForPosition() argument
2726 public PointF computeScrollVectorForPosition(int targetPosition) {
2734 ? targetPosition > firstChildPos
2735 : targetPosition < firstChildPos;
/frameworks/support/leanback/src/androidTest/java/androidx/leanback/widget/
DGridWidgetTest.java3479 int targetPosition = items.length - 1; in testSmoothscrollerCancelled() local
3480 mGridView.setSelectedPositionSmooth(targetPosition); in testSmoothscrollerCancelled()
3489 assertEquals(mGridView.getSelectedPosition(), targetPosition); in testSmoothscrollerCancelled() local
3490 assertSame(mGridView.getLayoutManager().findViewByPosition(targetPosition), in testSmoothscrollerCancelled()