rename function

main
Julian Gegner 2023-03-05 21:44:51 +01:00
parent 3d0c8d3724
commit 6c3915b6ab
2 changed files with 2 additions and 2 deletions

View File

@ -40,7 +40,7 @@ class MyHomePage extends StatelessWidget {
body: pageProvider.currentPageData['page'], body: pageProvider.currentPageData['page'],
bottomNavigationBar: NavigationBar( bottomNavigationBar: NavigationBar(
onDestinationSelected: isConfigured onDestinationSelected: isConfigured
? pageProvider.currentPage ? pageProvider.setCurrentPage
: (value) => AwesomeDialog( : (value) => AwesomeDialog(
context: context, context: context,
dialogType: DialogType.info, dialogType: DialogType.info,

View File

@ -14,7 +14,7 @@ class PageProvider extends ChangeNotifier {
int get currentPageIndex => _currentPage.index; int get currentPageIndex => _currentPage.index;
void currentPage(int index) { void setCurrentPage(int index) {
showForm = false; showForm = false;
_currentPage = Pages.values[index]; _currentPage = Pages.values[index];
notifyListeners(); notifyListeners();