feat:初始化工程
This commit is contained in:
11
lib/provider/app_provider.dart
Normal file
11
lib/provider/app_provider.dart
Normal file
@@ -0,0 +1,11 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
class AppProvider with ChangeNotifier {
|
||||
int _currentIndex = 0;
|
||||
int get currentIndex => _currentIndex;
|
||||
|
||||
void changeTab(int index) {
|
||||
_currentIndex = index;
|
||||
notifyListeners();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user