Status Update
Comments
lp...@google.com <lp...@google.com> #2
Thanks for filing, this is a known issue - to workaround the issue if you don't want scrollbars you can either disable them in your custom preferenceTheme, or do something such as applying the app's theme back again after leaving the PreferenceFragmentCompat.
ni...@gmail.com <ni...@gmail.com> #3
Hi, thanks for the answer.
Is there any chance this behaviour can be documented or maybe just setting android:scrollbars="vertical" in the preference layout instead of the theme?
Thank you.
Is there any chance this behaviour can be documented or maybe just setting android:scrollbars="vertical" in the preference layout instead of the theme?
Thank you.
Description
Version used: 1.2.1
Devices/Android versions reproduced on: Android 10, Android 14 emulator & Android 13 Pixel 7a
Sample project:
This is a regression introduced by:
The theme sets "android:scrollbars" to "vertical":
This change leaks through the activity theme and is not undone. This has caused a major performance issue in my app as it uses a lot of RecyclerViews (when the view holder are scrolled on screen and scrollbars is set to vertical, View calls awakenScrollbars() which wastes a lot of time on the UI thread because every View in the hierarchy does this).
Opening a PrefereneFragmentCompat should not impact all other views, as it causes sneaky issues like the aforementioned one. The behaviour can be easily observed in the sample project.
Thank you.