mirror of
https://github.com/SyncrowIOT/syncrow-app.git
synced 2025-11-27 21:34:54 +00:00
Fixed the overflow in the login screen, the page is scrollable.
- Fixed Scrolling wasent working in login screen - Changed Home page to indexed based view instead of PageView
This commit is contained in:
@ -17,10 +17,8 @@ class NavCubit extends Cubit<NavState> {
|
||||
|
||||
static NavCubit of(context) => BlocProvider.of<NavCubit>(context);
|
||||
|
||||
//functoin to do the important work when the user logs out
|
||||
static clear() {
|
||||
pageIndex = 0;
|
||||
pageController.jumpToPage(0);
|
||||
}
|
||||
|
||||
static int pageIndex = 0;
|
||||
@ -146,12 +144,9 @@ class NavCubit extends Cubit<NavState> {
|
||||
const MenuView(),
|
||||
];
|
||||
|
||||
static final PageController pageController = PageController();
|
||||
|
||||
void updatePageIndex(int index) {
|
||||
pageIndex = index;
|
||||
pageController.animateToPage(index,
|
||||
duration: const Duration(milliseconds: 150), curve: Curves.easeIn);
|
||||
|
||||
emit(NavChangePage());
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user