You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

25 lines
491 B
Dart

import 'package:flutter/material.dart';
import 'package:hmg_flutter_template/classes/enums.dart';
class BaseViewModel extends ChangeNotifier {
ViewState _state = ViewState.idle;
bool isInternetConnection = true;
ViewState get state => _state;
String error = "";
//TODO add the user login model when we need it
void setOnlyState(ViewState viewState) {
_state = viewState;
}
void setState(ViewState viewState) {
_state = viewState;
notifyListeners();
}
}