mirror of
https://github.com/GopeedLab/gopeed.git
synced 2026-11-06 16:40:32 +00:00
21 lines
473 B
Dart
21 lines
473 B
Dart
import 'package:flutter_riverpod/flutter_riverpod.dart';
|
|
|
|
import '../../../api/model/install_extension.dart';
|
|
|
|
final pendingExtensionInstallProvider = NotifierProvider<PendingExtensionInstall, InstallExtension?>(
|
|
PendingExtensionInstall.new,
|
|
);
|
|
|
|
class PendingExtensionInstall extends Notifier<InstallExtension?> {
|
|
@override
|
|
InstallExtension? build() => null;
|
|
|
|
void set(InstallExtension? install) {
|
|
state = install;
|
|
}
|
|
|
|
void clear() {
|
|
state = null;
|
|
}
|
|
}
|