mirror of
https://github.com/flutter/samples.git
synced 2025-11-10 14:58:34 +00:00
Veggie seasons update (#518)
This commit is contained in:
@@ -4,13 +4,13 @@
|
||||
|
||||
import 'dart:async';
|
||||
|
||||
import 'package:scoped_model/scoped_model.dart';
|
||||
import 'package:flutter/cupertino.dart';
|
||||
import 'package:veggieseasons/data/veggie.dart';
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
|
||||
/// A model class that mirrors the options in [SettingsScreen] and stores data
|
||||
/// in shared preferences.
|
||||
class Preferences extends Model {
|
||||
class Preferences extends ChangeNotifier {
|
||||
// Keys to use with shared preferences.
|
||||
static const _caloriesKey = 'calories';
|
||||
static const _preferredCategoriesKey = 'preferredCategories';
|
||||
|
||||
Reference in New Issue
Block a user