mirror of
https://github.com/HChaZZY/PiliPlus.git
synced 2025-12-06 09:13:48 +08:00
mod: add nav/search debounce option
Signed-off-by: bggRGjQaUbCoE <githubaccount56556@proton.me>
This commit is contained in:
@@ -38,6 +38,7 @@ class MainController extends GetxController {
|
||||
late int lastCheckUnreadAt = 0;
|
||||
|
||||
late final mainTabBarView = GStorage.mainTabBarView;
|
||||
late bool navSearchStreamDebounce = GStorage.navSearchStreamDebounce;
|
||||
|
||||
@override
|
||||
void onInit() {
|
||||
|
||||
@@ -264,8 +264,10 @@ class _MainAppState extends State<MainApp>
|
||||
? null
|
||||
: StreamBuilder(
|
||||
stream: _mainController.hideTabBar
|
||||
? _mainController.bottomBarStream.stream
|
||||
.throttle(const Duration(milliseconds: 500))
|
||||
? _mainController.navSearchStreamDebounce
|
||||
? _mainController.bottomBarStream.stream
|
||||
.throttle(const Duration(milliseconds: 500))
|
||||
: _mainController.bottomBarStream.stream
|
||||
: null,
|
||||
initialData: true,
|
||||
builder: (context, AsyncSnapshot snapshot) {
|
||||
|
||||
Reference in New Issue
Block a user