Home
last modified time | relevance | path

Searched refs:recyclerView (Results 1 – 25 of 41) sorted by relevance

12

/frameworks/opt/setupwizard/library/recyclerview/src/com/android/setupwizardlib/template/
DRecyclerViewScrollHandlingDelegate.java33 @Nullable private final RecyclerView recyclerView; field in RecyclerViewScrollHandlingDelegate
38 @NonNull RequireScrollMixin requireScrollMixin, @Nullable RecyclerView recyclerView) { in RecyclerViewScrollHandlingDelegate() argument
40 this.recyclerView = recyclerView; in RecyclerViewScrollHandlingDelegate()
44 if (recyclerView != null) { in canScrollDown()
46 final int offset = recyclerView.computeVerticalScrollOffset(); in canScrollDown()
48 recyclerView.computeVerticalScrollRange() - recyclerView.computeVerticalScrollExtent(); in canScrollDown()
56 if (this.recyclerView != null) { in startListening()
57 this.recyclerView.addOnScrollListener( in startListening()
60 public void onScrolled(RecyclerView recyclerView, int dx, int dy) { in startListening()
75 if (recyclerView != null) { in pageScrollDown()
[all …]
DRecyclerMixin.java54 @NonNull private final RecyclerView recyclerView; field in RecyclerMixin
74 public RecyclerMixin(@NonNull TemplateLayout layout, @NonNull RecyclerView recyclerView) { in RecyclerMixin() argument
80 this.recyclerView = recyclerView; in RecyclerMixin()
81 this.recyclerView.setLayoutManager(new LinearLayoutManager(templateLayout.getContext())); in RecyclerMixin()
83 if (recyclerView instanceof HeaderRecyclerView) { in RecyclerMixin()
84 header = ((HeaderRecyclerView) recyclerView).getHeader(); in RecyclerMixin()
87 this.recyclerView.addItemDecoration(dividerDecoration); in RecyclerMixin()
133 return recyclerView; in getRecyclerView()
166 final RecyclerView.Adapter<? extends ViewHolder> adapter = recyclerView.getAdapter(); in getAdapter()
175 recyclerView.setAdapter(adapter); in setAdapter()
[all …]
/frameworks/base/core/java/com/android/internal/app/
DChooserRecyclerViewAccessibilityDelegate.java32 ChooserRecyclerViewAccessibilityDelegate(RecyclerView recyclerView) { in ChooserRecyclerViewAccessibilityDelegate() argument
33 super(recyclerView); in ChooserRecyclerViewAccessibilityDelegate()
58 private void ensureViewOnScreenVisibility(RecyclerView recyclerView, View view) { in ensureViewOnScreenVisibility() argument
59 View child = recyclerView.findContainingItemView(view); in ensureViewOnScreenVisibility()
63 recyclerView.getBoundsOnScreen(mTempRect, true); in ensureViewOnScreenVisibility()
78 nestedVerticalScrollBy(recyclerView, dy); in ensureViewOnScreenVisibility()
81 private void nestedVerticalScrollBy(RecyclerView recyclerView, int dy) { in nestedVerticalScrollBy() argument
85 recyclerView.startNestedScroll(View.SCROLL_AXIS_VERTICAL); in nestedVerticalScrollBy()
86 if (recyclerView.dispatchNestedPreScroll(0, dy, mConsumed, null)) { in nestedVerticalScrollBy()
89 recyclerView.scrollBy(0, dy); in nestedVerticalScrollBy()
[all …]
DChooserMultiProfilePagerAdapter.java83 profileDescriptor.recyclerView.setAccessibilityDelegateCompat( in createProfileDescriptor()
84 new ChooserRecyclerViewAccessibilityDelegate(profileDescriptor.recyclerView)); in createProfileDescriptor()
93 return getItem(index).recyclerView; in getListViewForIndex()
127 final RecyclerView recyclerView = getItem(pageIndex).recyclerView; in setupListAdapter() local
130 GridLayoutManager glm = (GridLayoutManager) recyclerView.getLayoutManager(); in setupListAdapter()
205 private RecyclerView recyclerView; field in ChooserMultiProfilePagerAdapter.ChooserProfileDescriptor
209 recyclerView = rootView.findViewById(R.id.resolver_list); in ChooserProfileDescriptor()
/frameworks/base/core/java/com/android/internal/view/
DRecyclerViewCaptureHelper.java67 public void onScrollRequested(@NonNull ViewGroup recyclerView, Rect scrollBounds, in onScrollRequested() argument
74 if (!recyclerView.isVisibleToUser() || recyclerView.getChildCount() == 0) { in onScrollRequested()
87 View anchor = findChildNearestTarget(recyclerView, requestedContainerBounds); in onScrollRequested()
95 recyclerView.offsetRectIntoDescendantCoords(anchor, requestedContentBounds); in onScrollRequested()
101 int remainingHeight = recyclerView.getHeight() - recyclerView.getPaddingTop() in onScrollRequested()
102 - recyclerView.getPaddingBottom() - input.height(); in onScrollRequested()
107 if (recyclerView.requestChildRectangleOnScreen(anchor, input, true)) { in onScrollRequested()
121 recyclerView.offsetDescendantRectToMyCoords(anchor, requestedContainerBounds); in onScrollRequested()
124 recyclerView.getLocalVisibleRect(recyclerLocalVisible); in onScrollRequested()
/frameworks/layoutlib/bridge/src/com/android/layoutlib/bridge/android/support/
DRecyclerViewUtil.java54 public static void setAdapter(@NonNull View recyclerView, @NonNull BridgeContext context, in setAdapter() argument
57 ReflectionUtils.getParentClass(recyclerView, RecyclerViewUtil.CN_RECYCLER_VIEW); in setAdapter()
69 …setLayoutManager(recyclerView, recyclerViewPackageName, layoutMgrClassName, context, layoutlibCall… in setAdapter()
72 setProperty(recyclerView, adapterClassName, adapter, "setAdapter"); in setAdapter()
86 private static void setLayoutManager(@NonNull View recyclerView, in setLayoutManager() argument
90 if (getLayoutManager(recyclerView) == null) { in setLayoutManager()
96 setProperty(recyclerView, layoutMgrClassName, layoutManager, "setLayoutManager"); in setLayoutManager()
115 private static Object getLayoutManager(View recyclerView) throws ReflectionException { in getLayoutManager() argument
116 return invoke(getMethod(recyclerView.getClass(), "getLayoutManager"), recyclerView); in getLayoutManager()
/frameworks/base/packages/SystemUI/src/com/android/systemui/wallet/ui/
DDotIndicatorDecoration.java59 Rect rect, View view, RecyclerView recyclerView, RecyclerView.State state) { in getItemOffsets() argument
60 super.getItemOffsets(rect, view, recyclerView, state); in getItemOffsets()
61 if (recyclerView.getAdapter().getItemCount() > 1) { in getItemOffsets()
68 public void onDrawOver(Canvas canvas, RecyclerView recyclerView, RecyclerView.State state) { in onDrawOver() argument
69 super.onDrawOver(canvas, recyclerView, state); in onDrawOver()
71 mCardCarousel = (WalletCardCarousel) recyclerView; in onDrawOver()
72 int itemCount = recyclerView.getAdapter().getItemCount(); in onDrawOver()
79 float animationStartOffset = recyclerView.getWidth() / 6f; in onDrawOver()
93 (recyclerView.getWidth() - totalWidth) / 2f, in onDrawOver()
94 recyclerView.getHeight() - mDotMargin); in onDrawOver()
/frameworks/base/core/java/com/android/internal/widget/helper/
DItemTouchUIUtilImpl.java31 public void onDraw(Canvas c, RecyclerView recyclerView, View view, in onDraw() argument
38 float newElevation = 1f + findMaxElevation(recyclerView, view); in onDraw()
48 private float findMaxElevation(RecyclerView recyclerView, View itemView) { in findMaxElevation() argument
49 final int childCount = recyclerView.getChildCount(); in findMaxElevation()
52 final View child = recyclerView.getChildAt(i); in findMaxElevation()
81 public void onDrawOver(Canvas c, RecyclerView recyclerView, in onDrawOver() argument
DItemTouchHelper.java299 public boolean onInterceptTouchEvent(RecyclerView recyclerView, MotionEvent event) {
344 public void onTouchEvent(RecyclerView recyclerView, MotionEvent event) {
449 public void attachToRecyclerView(@Nullable RecyclerView recyclerView) { in attachToRecyclerView() argument
450 if (mRecyclerView == recyclerView) { in attachToRecyclerView()
456 mRecyclerView = recyclerView; in attachToRecyclerView()
458 final Resources resources = recyclerView.getResources(); in attachToRecyclerView()
1515 public abstract int getMovementFlags(RecyclerView recyclerView, in getMovementFlags() argument
1546 final int getAbsoluteMovementFlags(RecyclerView recyclerView, in getAbsoluteMovementFlags() argument
1548 final int flags = getMovementFlags(recyclerView, viewHolder); in getAbsoluteMovementFlags()
1549 return convertToAbsoluteDirection(flags, recyclerView.getLayoutDirection()); in getAbsoluteMovementFlags()
[all …]
DItemTouchUIUtil.java43 void onDraw(Canvas c, RecyclerView recyclerView, View view, in onDraw() argument
50 void onDrawOver(Canvas c, RecyclerView recyclerView, View view, in onDrawOver() argument
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/screenshot/
DRecyclerViewActivity.java43 RecyclerView recyclerView = new RecyclerView(this); in onCreate() local
44 recyclerView.setLayoutManager(new LinearLayoutManager(this)); in onCreate()
45 recyclerView.setAdapter(new TestAdapter()); in onCreate()
46 recyclerView.setLayoutParams(new LayoutParams(MATCH_PARENT, MATCH_PARENT)); in onCreate()
47 setContentView(recyclerView); in onCreate()
/frameworks/base/core/java/com/android/internal/widget/
DGapWorker.java152 public void add(RecyclerView recyclerView) { in add() argument
153 if (RecyclerView.DEBUG && mRecyclerViews.contains(recyclerView)) { in add()
156 mRecyclerViews.add(recyclerView); in add()
159 public void remove(RecyclerView recyclerView) { in remove() argument
160 boolean removeSuccess = mRecyclerViews.remove(recyclerView); in remove()
169 void postFromTraversal(RecyclerView recyclerView, int prefetchDx, int prefetchDy) { in postFromTraversal() argument
170 if (recyclerView.isAttachedToWindow()) { in postFromTraversal()
171 if (RecyclerView.DEBUG && !mRecyclerViews.contains(recyclerView)) { in postFromTraversal()
175 mPostTimeNs = recyclerView.getNanoTime(); in postFromTraversal()
176 recyclerView.post(this); in postFromTraversal()
[all …]
/frameworks/base/tests/UiBench/src/com/android/test/uibench/recyclerview/
DRvCompatListActivity.java42 RecyclerView recyclerView = (RecyclerView) inflater.inflate( in onCreateView() local
44 recyclerView.setLayoutManager(layoutManager); in onCreateView()
45 recyclerView.setAdapter(adapter); in onCreateView()
46 return recyclerView; in onCreateView()
/frameworks/base/packages/SystemUI/src/com/android/systemui/controls/management/
DStructureAdapter.kt48 private val recyclerView: RecyclerView constant
52 recyclerView = itemView.requireViewById<RecyclerView>(R.id.listAll) in <lambda>()
68 recyclerView.apply { in setUpRecyclerView()
70 layoutManager = GridLayoutManager(recyclerView.context, spanCount).apply { in setUpRecyclerView()
DControlsProviderSelectorActivity.kt69 private lateinit var recyclerView: RecyclerView in <lambda>() variable in com.android.systemui.controls.management.ControlsProviderSelectorActivity
107 recyclerView = requireViewById(R.id.list) in <lambda>()
108 recyclerView.layoutManager = LinearLayoutManager(applicationContext) in <lambda>()
140 recyclerView.alpha = 0.0f in <lambda>()
141 recyclerView.adapter = AppAdapter( in <lambda>()
157 ControlsAnimations.enterAnimation(recyclerView).start() in <lambda>()
DControlsEditingActivity.kt246 val recyclerView = requireViewById<RecyclerView>(R.id.list) in setUpList() constant
247 recyclerView.alpha = 0.0f in setUpList()
254 ControlsAnimations.enterAnimation(recyclerView).start() in setUpList()
265 recyclerView.apply { in setUpList()
267 layoutManager = object : GridLayoutManager(recyclerView.context, spanCount) { in setUpList()
290 ItemTouchHelper(model.itemTouchHelperCallback).attachToRecyclerView(recyclerView) in setUpList()
/frameworks/base/core/tests/coretests/src/com/android/internal/view/
DRecyclerViewCaptureHelperTest.java47 RecyclerView recyclerView = new RecyclerView(parent.getContext()); in createScrollableContent() local
48 recyclerView.setAdapter(new TestAdapter()); in createScrollableContent()
51 recyclerView.setLayoutManager(layoutManager); in createScrollableContent()
52 return recyclerView; in createScrollableContent()
/frameworks/base/packages/SettingsLib/src/com/android/settingslib/core/instrumentation/
DSettingsJankMonitor.kt47 recyclerView: RecyclerView, in detectSwitchPreferenceClickJank()
50 val adapter = recyclerView.adapter as? PreferenceGroupAdapter ?: return in detectSwitchPreferenceClickJank()
52 val viewHolder = recyclerView.findViewHolderForAdapterPosition(adapterPosition) ?: return in detectSwitchPreferenceClickJank()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/bluetooth/qsdialog/
DBluetoothTileDialogDelegateTest.kt153 val recyclerView = dialog.requireViewById<RecyclerView>(R.id.device_list) in testShowDialog_createRecyclerViewWithAdapter() constant
155 assertThat(recyclerView).isNotNull() in testShowDialog_createRecyclerViewWithAdapter()
156 assertThat(recyclerView.visibility).isEqualTo(VISIBLE) in testShowDialog_createRecyclerViewWithAdapter()
157 assertThat(recyclerView.adapter).isNotNull() in testShowDialog_createRecyclerViewWithAdapter()
158 assertThat(recyclerView.layoutManager is LinearLayoutManager).isTrue() in testShowDialog_createRecyclerViewWithAdapter()
175 val recyclerView = dialog.requireViewById<RecyclerView>(R.id.device_list) in testShowDialog_displayBluetoothDevice() constant
176 val adapter = recyclerView?.adapter as BluetoothTileDialogDelegate.Adapter in testShowDialog_displayBluetoothDevice()
246 val recyclerView = dialog.requireViewById<RecyclerView>(R.id.device_list) in testOnDeviceUpdated_hideSeeAll_showPairNew() constant
247 val adapter = recyclerView?.adapter as BluetoothTileDialogDelegate.Adapter in testOnDeviceUpdated_hideSeeAll_showPairNew()
/frameworks/base/packages/SystemUI/src/com/android/systemui/accessibility/floatingmenu/
DMenuListViewTouchHandler.java55 public boolean onInterceptTouchEvent(@NonNull RecyclerView recyclerView, in onInterceptTouchEvent() argument
58 final View menuView = (View) recyclerView.getParent(); in onInterceptTouchEvent()
67 mTouchSlop = ViewConfiguration.get(recyclerView.getContext()).getScaledTouchSlop(); in onInterceptTouchEvent()
126 public void onTouchEvent(@NonNull RecyclerView recyclerView, in onTouchEvent() argument
/frameworks/base/packages/SystemUI/src/com/android/systemui/qs/customize/
DQSCustomizerController.java140 RecyclerView recyclerView = mView.getRecyclerView(); in onViewAttached() local
141 recyclerView.setAdapter(mTileAdapter); in onViewAttached()
142 mTileAdapter.getItemTouchHelper().attachToRecyclerView(recyclerView); in onViewAttached()
159 recyclerView, new RecyclerView.State()); in onViewAttached()
166 recyclerView.setLayoutManager(layout); in onViewAttached()
167 recyclerView.addItemDecoration(mTileAdapter.getItemDecoration()); in onViewAttached()
168 recyclerView.addItemDecoration(mTileAdapter.getMarginItemDecoration()); in onViewAttached()
/frameworks/opt/setupwizard/library/recyclerview/src/com/android/setupwizardlib/
DSetupWizardRecyclerLayout.java110 final View recyclerView = findViewById(R.id.suw_recycler_view); in onTemplateInflated() local
111 if (recyclerView instanceof RecyclerView) { in onTemplateInflated()
112 mRecyclerMixin = new RecyclerMixin(this, (RecyclerView) recyclerView); in onTemplateInflated()
DGlifRecyclerLayout.java91 final View recyclerView = findViewById(R.id.suw_recycler_view); in onTemplateInflated() local
92 if (recyclerView instanceof RecyclerView) { in onTemplateInflated()
93 mRecyclerMixin = new RecyclerMixin(this, (RecyclerView) recyclerView); in onTemplateInflated()
DGlifPreferenceLayout.java111 RecyclerView recyclerView = in onTemplateInflated() local
113 mRecyclerMixin = new RecyclerMixin(this, recyclerView); in onTemplateInflated()
DSetupWizardPreferenceLayout.java110 RecyclerView recyclerView = in onTemplateInflated() local
112 mRecyclerMixin = new RecyclerMixin(this, recyclerView); in onTemplateInflated()

12