Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Made show scrollbar setting stick after opening search #4724

Merged
merged 2 commits into from
Aug 26, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -178,6 +178,7 @@ public void onScrolled(@NonNull RecyclerView recyclerView, int dx, int dy) {
* state.
*/
private boolean mIsSearching;
boolean showFastScroller;
private boolean mRebindAdaptersAfterSearchAnimation;
private int mNavBarScrimHeight = 0;
public SearchRecyclerView mSearchRecyclerView;
Expand Down Expand Up @@ -259,7 +260,7 @@ public AllAppsSearchUiDelegate getSearchUiDelegate() {
* onFinishInflate -> onPostCreate
*/
protected void initContent() {
boolean showFastScroller = PreferenceExtensionsKt.firstBlocking(pref2.getShowScrollbar());
showFastScroller = PreferenceExtensionsKt.firstBlocking(pref2.getShowScrollbar());

mMainAdapterProvider = mSearchUiDelegate.createMainAdapterProvider();

Expand Down Expand Up @@ -409,6 +410,7 @@ private void animateToSearchState(boolean goingToSearch, long durationMs) {
} else if (mAllAppsTransitionController != null) {
// If exiting search, revert predictive back scale on all apps
mAllAppsTransitionController.animateAllAppsToNoScale();
mFastScroller.setVisibility(showFastScroller ? VISIBLE : INVISIBLE);
}
mSearchTransitionController.animateToSearchState(goingToSearch, durationMs,
/* onEndRunnable = */ () -> {
Expand Down