From 6c3915b6ab3d4949521ba6e56221b64e77886866 Mon Sep 17 00:00:00 2001 From: Crondung <1922635@stud.hs-mannheim.de> Date: Sun, 5 Mar 2023 21:44:51 +0100 Subject: [PATCH] rename function --- lib/pages/main_page.dart | 2 +- lib/providers/page_provider.dart | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/pages/main_page.dart b/lib/pages/main_page.dart index ef396ef..9d6c77b 100644 --- a/lib/pages/main_page.dart +++ b/lib/pages/main_page.dart @@ -40,7 +40,7 @@ class MyHomePage extends StatelessWidget { body: pageProvider.currentPageData['page'], bottomNavigationBar: NavigationBar( onDestinationSelected: isConfigured - ? pageProvider.currentPage + ? pageProvider.setCurrentPage : (value) => AwesomeDialog( context: context, dialogType: DialogType.info, diff --git a/lib/providers/page_provider.dart b/lib/providers/page_provider.dart index ce1741a..8184ee7 100644 --- a/lib/providers/page_provider.dart +++ b/lib/providers/page_provider.dart @@ -14,7 +14,7 @@ class PageProvider extends ChangeNotifier { int get currentPageIndex => _currentPage.index; - void currentPage(int index) { + void setCurrentPage(int index) { showForm = false; _currentPage = Pages.values[index]; notifyListeners();