Signed-off-by: dom <githubaccount56556@proton.me>
This commit is contained in:
dom
2026-01-23 19:50:11 +08:00
parent 7eaf05839a
commit 0ab07a713e
22 changed files with 443 additions and 470 deletions

View File

@@ -30,7 +30,8 @@ class MainController extends GetxController
List<NavigationBarType> navigationBars = <NavigationBarType>[];
RxBool? bottomBar;
RxBool? showBottomBar;
bool useBottomNav = false;
late dynamic controller;
final RxInt selectedIndex = 0.obs;
@@ -81,8 +82,8 @@ class MainController extends GetxController
)
: PageController(initialPage: selectedIndex.value);
if (navigationBars.length > 1 && Pref.hideTabBar) {
bottomBar = true.obs;
if (!useSideBar && navigationBars.length > 1 && Pref.hideBottomBar) {
showBottomBar = true.obs;
}
dynamicBadgeMode = Pref.dynamicBadgeMode;
@@ -314,13 +315,13 @@ class MainController extends GetxController
void setSearchBar() {
if (hasHome) {
homeController.searchBar?.value = true;
homeController.showSearchBar?.value = true;
}
}
@override
void onClose() {
bottomBar?.close();
showBottomBar?.close();
controller.dispose();
super.onClose();
}