zhanghai/AndroidFastScroll là một trong những repo tập trung di động mà TopGit theo dõi, hiện có 749 sao, viết chủ yếu bằng Java. Fast scroll for Android RecyclerView and more
Tóm tắt dựng từ metadata GitHub của chính dự án — chưa có bài review TopGit. Trang sẽ tự động cập nhật khi bài review đầy đủ được xuất bản.
VÌ SAO CHƯA CÓ REVIEW
TopGit viết bài đầy đủ cho repo có nhiều sao nhất và được yêu cầu nhiều nhất. Trang này là snapshot trong thời gian chờ — xem README gốc ở tab READ ME.
Simply create a FastScroller with FastScrollerBuilder, and enjoy!
new FastScrollerBuilder(recyclerView).build();
You can also implement PopupTextProvider in your RecyclerView.Adapter to show a popup.
For more customization, please use the methods on FastScrollerBuilder. Namely:
setViewHelper() allows providing a custom ViewHelper to support more views.
setPopupTextProvider() allows providing a custom PopupTextProvider if your RecyclerView.Adapter cannot implement that interface.
setPadding() allows setting a custom padding for the scrollbar, instead of the padding of the view.
setTrackDrawable() and setThumbDrawable() allow setting custom drawables for the scrollbar. The android:state_pressed state will be updated for them so you can use a selector. The track drawable needs to have an intrinsic width and the thumb drawable needs to have an intrinsic size, in order to allow proper touch event handling.
setPopupStyle() allows customizing the popup view with a lambda that will receive the view.
setAnimationHelper() allows providing a custom AnimationHelper to use an alternative scrollbar animation.
disableScrollbarAutoHide() allows disabling the auto hide animation for scrollbar. This implies using a DefaultAnimationHelper.
useDefaultStyle() and useMd2Style() allow using the predefined styles, which sets the drawables and popup style. useDefaultStyle(), as its name suggests, is the default style when a FastScrollerBuilder is created.
The default ViewHelper implementation for RecyclerView supports both LinearLayoutManager and GridLayoutManager, but assumes that each item has the same height when calculating scroll, as there's no common way to deal with variable item height. If you know how to measure for scrolling in your specific case, you can provide your own ViewHelper implementation and fast scroll will work correctly again.
If you are using any RecyclerView.ItemDecoration that implements onDrawOver(), you might be interested in FixItemDecorationRecyclerView which can fix the drawing order.
If you are using any other library that makes use of RecyclerView.OnItemTouchListener (e.g. recyclerview-selection), you might be interested in FixOnItemTouchListenerRecyclerView which can correctly handle cancellations when dispatching touch events to listeners. You may also want to configure this library before others so that this library can take precedence in touch event handling.
You can also refer to the sample app source for how things like window insets and lift on scroll are implemented.
License
Copyright 2019 Google LLC
Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at
https://www.apache.org/licenses/LICENSE-2.0
Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.
Trang TopGit này là một snapshot — tab "Readme" hiển thị nguyên văn README của repo (đã bỏ link, giữ ảnh). Repo GitHub ở github.com/zhanghai/AndroidFastScroll là nguồn chính thức.
zhanghai/AndroidFastScroll có những chủ đề gì?
GitHub topics của zhanghai/AndroidFastScroll: "android", "android-library", "fastscroll", "nestedscrollview", "recyclerview", "scrollview", "webview". TopGit xếp repo vào nhóm Mobile.
zhanghai/AndroidFastScroll có phải mã nguồn mở không?
Có — zhanghai/AndroidFastScroll phát hành theo license Apache-2.0, nghĩa là mã nguồn mở để đọc, fork và (tùy license) tái sử dụng. Mã: github.com/zhanghai/AndroidFastScroll.
zhanghai/AndroidFastScroll có trang demo không?
Dự án có trang chủ ở https://play.google.com/store/apps/details?id=me.zhanghai.android.fastscroll.sample. Tab "Readme" ở trang này thường có ảnh chụp và hướng dẫn bắt đầu nhanh.
zhanghai/AndroidFastScroll còn đang phát triển không?
Commit gần nhất trên zhanghai/AndroidFastScroll là 3.3 năm trước (theo timestamp GitHub). Repo có 85 fork — một chỉ báo về mức độ quan tâm của cộng đồng.
zhanghai/AndroidFastScroll dùng license gì?
zhanghai/AndroidFastScroll phát hành theo license Apache-2.0. Nên mở file LICENSE trên GitHub để xác nhận — license metadata đôi khi lệch với thực tế dự án.
Đọc đầy đủ README ở tab phía trên.
Chưa chắc AndroidFastScroll có hợp với bạn?
Để ChatGPT, Claude hoặc Perplexity tìm hiểu giúp — bấm bên dưới và xem AI nói gì về AndroidFastScroll.