Refactor preferences

This commit is contained in:
problematicconsumer
2024-03-02 22:53:14 +03:30
parent 201ea5e88d
commit 2a994dc348
32 changed files with 1104 additions and 1389 deletions

View File

@@ -22,7 +22,7 @@ class PerAppProxyPage extends HookConsumerWidget with PresLogger {
final localizations = MaterialLocalizations.of(context);
final asyncPackages = ref.watch(installedPackagesInfoProvider);
final perAppProxyMode = ref.watch(perAppProxyModeNotifierProvider);
final perAppProxyMode = ref.watch(Preferences.perAppProxyMode);
final perAppProxyList = ref.watch(perAppProxyListProvider);
final showSystemApps = useState(true);
@@ -130,7 +130,7 @@ class PerAppProxyPage extends HookConsumerWidget with PresLogger {
groupValue: perAppProxyMode,
onChanged: (value) async {
await ref
.read(perAppProxyModeNotifierProvider.notifier)
.read(Preferences.perAppProxyMode.notifier)
.update(e);
if (e == PerAppProxyMode.off && context.mounted) {
context.pop();