mirror of
https://github.com/austinried/subtracks.git
synced 2026-03-28 23:32:42 +01:00
chore: upgrade to Flutter 3.24.5
At the time of writing the latest Flutter version.
This commit is contained in:
@@ -111,13 +111,13 @@ class OfflineIndicator extends HookConsumerWidget {
|
||||
),
|
||||
child: FilledButton.tonal(
|
||||
style: const ButtonStyle(
|
||||
padding: MaterialStatePropertyAll<EdgeInsetsGeometry>(
|
||||
padding: WidgetStatePropertyAll<EdgeInsetsGeometry>(
|
||||
EdgeInsets.zero,
|
||||
),
|
||||
fixedSize: MaterialStatePropertyAll<Size>(
|
||||
fixedSize: WidgetStatePropertyAll<Size>(
|
||||
Size(42, 42),
|
||||
),
|
||||
minimumSize: MaterialStatePropertyAll<Size>(
|
||||
minimumSize: WidgetStatePropertyAll<Size>(
|
||||
Size(42, 42),
|
||||
),
|
||||
),
|
||||
|
||||
@@ -53,4 +53,5 @@ final lastBottomNavStateServiceProvider =
|
||||
);
|
||||
|
||||
typedef _$LastBottomNavStateService = AsyncNotifier<void>;
|
||||
// ignore_for_file: unnecessary_raw_strings, subtype_of_sealed_class, invalid_use_of_internal_member, do_not_use_environment, prefer_const_constructors, public_member_api_docs, avoid_private_typedef_functions
|
||||
// ignore_for_file: type=lint
|
||||
// ignore_for_file: subtype_of_sealed_class, invalid_use_of_internal_member, invalid_use_of_visible_for_testing_member
|
||||
|
||||
@@ -30,8 +30,6 @@ class _SystemHash {
|
||||
}
|
||||
}
|
||||
|
||||
typedef AlbumsCategoryListRef = AutoDisposeStreamProviderRef<List<Album>>;
|
||||
|
||||
/// See also [albumsCategoryList].
|
||||
@ProviderFor(albumsCategoryList)
|
||||
const albumsCategoryListProvider = AlbumsCategoryListFamily();
|
||||
@@ -79,10 +77,10 @@ class AlbumsCategoryListProvider
|
||||
extends AutoDisposeStreamProvider<List<Album>> {
|
||||
/// See also [albumsCategoryList].
|
||||
AlbumsCategoryListProvider(
|
||||
this.opt,
|
||||
) : super.internal(
|
||||
ListQuery opt,
|
||||
) : this._internal(
|
||||
(ref) => albumsCategoryList(
|
||||
ref,
|
||||
ref as AlbumsCategoryListRef,
|
||||
opt,
|
||||
),
|
||||
from: albumsCategoryListProvider,
|
||||
@@ -94,10 +92,44 @@ class AlbumsCategoryListProvider
|
||||
dependencies: AlbumsCategoryListFamily._dependencies,
|
||||
allTransitiveDependencies:
|
||||
AlbumsCategoryListFamily._allTransitiveDependencies,
|
||||
opt: opt,
|
||||
);
|
||||
|
||||
AlbumsCategoryListProvider._internal(
|
||||
super._createNotifier, {
|
||||
required super.name,
|
||||
required super.dependencies,
|
||||
required super.allTransitiveDependencies,
|
||||
required super.debugGetCreateSourceHash,
|
||||
required super.from,
|
||||
required this.opt,
|
||||
}) : super.internal();
|
||||
|
||||
final ListQuery opt;
|
||||
|
||||
@override
|
||||
Override overrideWith(
|
||||
Stream<List<Album>> Function(AlbumsCategoryListRef provider) create,
|
||||
) {
|
||||
return ProviderOverride(
|
||||
origin: this,
|
||||
override: AlbumsCategoryListProvider._internal(
|
||||
(ref) => create(ref as AlbumsCategoryListRef),
|
||||
from: from,
|
||||
name: null,
|
||||
dependencies: null,
|
||||
allTransitiveDependencies: null,
|
||||
debugGetCreateSourceHash: null,
|
||||
opt: opt,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
AutoDisposeStreamProviderElement<List<Album>> createElement() {
|
||||
return _AlbumsCategoryListProviderElement(this);
|
||||
}
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) {
|
||||
return other is AlbumsCategoryListProvider && other.opt == opt;
|
||||
@@ -111,4 +143,19 @@ class AlbumsCategoryListProvider
|
||||
return _SystemHash.finish(hash);
|
||||
}
|
||||
}
|
||||
// ignore_for_file: unnecessary_raw_strings, subtype_of_sealed_class, invalid_use_of_internal_member, do_not_use_environment, prefer_const_constructors, public_member_api_docs, avoid_private_typedef_functions
|
||||
|
||||
mixin AlbumsCategoryListRef on AutoDisposeStreamProviderRef<List<Album>> {
|
||||
/// The parameter `opt` of this provider.
|
||||
ListQuery get opt;
|
||||
}
|
||||
|
||||
class _AlbumsCategoryListProviderElement
|
||||
extends AutoDisposeStreamProviderElement<List<Album>>
|
||||
with AlbumsCategoryListRef {
|
||||
_AlbumsCategoryListProviderElement(super.provider);
|
||||
|
||||
@override
|
||||
ListQuery get opt => (origin as AlbumsCategoryListProvider).opt;
|
||||
}
|
||||
// ignore_for_file: type=lint
|
||||
// ignore_for_file: subtype_of_sealed_class, invalid_use_of_internal_member, invalid_use_of_visible_for_testing_member
|
||||
|
||||
@@ -60,8 +60,6 @@ class _SystemHash {
|
||||
}
|
||||
}
|
||||
|
||||
typedef LibraryListQueryRef = ProviderRef<LibraryListQuery>;
|
||||
|
||||
/// See also [libraryListQuery].
|
||||
@ProviderFor(libraryListQuery)
|
||||
const libraryListQueryProvider = LibraryListQueryFamily();
|
||||
@@ -108,10 +106,10 @@ class LibraryListQueryFamily extends Family<LibraryListQuery> {
|
||||
class LibraryListQueryProvider extends Provider<LibraryListQuery> {
|
||||
/// See also [libraryListQuery].
|
||||
LibraryListQueryProvider(
|
||||
this.index,
|
||||
) : super.internal(
|
||||
int index,
|
||||
) : this._internal(
|
||||
(ref) => libraryListQuery(
|
||||
ref,
|
||||
ref as LibraryListQueryRef,
|
||||
index,
|
||||
),
|
||||
from: libraryListQueryProvider,
|
||||
@@ -123,10 +121,44 @@ class LibraryListQueryProvider extends Provider<LibraryListQuery> {
|
||||
dependencies: LibraryListQueryFamily._dependencies,
|
||||
allTransitiveDependencies:
|
||||
LibraryListQueryFamily._allTransitiveDependencies,
|
||||
index: index,
|
||||
);
|
||||
|
||||
LibraryListQueryProvider._internal(
|
||||
super._createNotifier, {
|
||||
required super.name,
|
||||
required super.dependencies,
|
||||
required super.allTransitiveDependencies,
|
||||
required super.debugGetCreateSourceHash,
|
||||
required super.from,
|
||||
required this.index,
|
||||
}) : super.internal();
|
||||
|
||||
final int index;
|
||||
|
||||
@override
|
||||
Override overrideWith(
|
||||
LibraryListQuery Function(LibraryListQueryRef provider) create,
|
||||
) {
|
||||
return ProviderOverride(
|
||||
origin: this,
|
||||
override: LibraryListQueryProvider._internal(
|
||||
(ref) => create(ref as LibraryListQueryRef),
|
||||
from: from,
|
||||
name: null,
|
||||
dependencies: null,
|
||||
allTransitiveDependencies: null,
|
||||
debugGetCreateSourceHash: null,
|
||||
index: index,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
ProviderElement<LibraryListQuery> createElement() {
|
||||
return _LibraryListQueryProviderElement(this);
|
||||
}
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) {
|
||||
return other is LibraryListQueryProvider && other.index == index;
|
||||
@@ -141,6 +173,19 @@ class LibraryListQueryProvider extends Provider<LibraryListQuery> {
|
||||
}
|
||||
}
|
||||
|
||||
mixin LibraryListQueryRef on ProviderRef<LibraryListQuery> {
|
||||
/// The parameter `index` of this provider.
|
||||
int get index;
|
||||
}
|
||||
|
||||
class _LibraryListQueryProviderElement extends ProviderElement<LibraryListQuery>
|
||||
with LibraryListQueryRef {
|
||||
_LibraryListQueryProviderElement(super.provider);
|
||||
|
||||
@override
|
||||
int get index => (origin as LibraryListQueryProvider).index;
|
||||
}
|
||||
|
||||
String _$lastLibraryStateServiceHash() =>
|
||||
r'a49e26b5dc0fcb0f697ec2def08e7336f64c4cb3';
|
||||
|
||||
@@ -173,4 +218,5 @@ final libraryListsProvider =
|
||||
);
|
||||
|
||||
typedef _$LibraryLists = Notifier<IList<LibraryListQuery>>;
|
||||
// ignore_for_file: unnecessary_raw_strings, subtype_of_sealed_class, invalid_use_of_internal_member, do_not_use_environment, prefer_const_constructors, public_member_api_docs, avoid_private_typedef_functions
|
||||
// ignore_for_file: type=lint
|
||||
// ignore_for_file: subtype_of_sealed_class, invalid_use_of_internal_member, invalid_use_of_visible_for_testing_member
|
||||
|
||||
@@ -29,8 +29,6 @@ class _SystemHash {
|
||||
}
|
||||
}
|
||||
|
||||
typedef SongsListRef = AutoDisposeFutureProviderRef<List<Song>>;
|
||||
|
||||
/// See also [songsList].
|
||||
@ProviderFor(songsList)
|
||||
const songsListProvider = SongsListFamily();
|
||||
@@ -77,10 +75,10 @@ class SongsListFamily extends Family<AsyncValue<List<Song>>> {
|
||||
class SongsListProvider extends AutoDisposeFutureProvider<List<Song>> {
|
||||
/// See also [songsList].
|
||||
SongsListProvider(
|
||||
this.opt,
|
||||
) : super.internal(
|
||||
ListQuery opt,
|
||||
) : this._internal(
|
||||
(ref) => songsList(
|
||||
ref,
|
||||
ref as SongsListRef,
|
||||
opt,
|
||||
),
|
||||
from: songsListProvider,
|
||||
@@ -91,10 +89,44 @@ class SongsListProvider extends AutoDisposeFutureProvider<List<Song>> {
|
||||
: _$songsListHash,
|
||||
dependencies: SongsListFamily._dependencies,
|
||||
allTransitiveDependencies: SongsListFamily._allTransitiveDependencies,
|
||||
opt: opt,
|
||||
);
|
||||
|
||||
SongsListProvider._internal(
|
||||
super._createNotifier, {
|
||||
required super.name,
|
||||
required super.dependencies,
|
||||
required super.allTransitiveDependencies,
|
||||
required super.debugGetCreateSourceHash,
|
||||
required super.from,
|
||||
required this.opt,
|
||||
}) : super.internal();
|
||||
|
||||
final ListQuery opt;
|
||||
|
||||
@override
|
||||
Override overrideWith(
|
||||
FutureOr<List<Song>> Function(SongsListRef provider) create,
|
||||
) {
|
||||
return ProviderOverride(
|
||||
origin: this,
|
||||
override: SongsListProvider._internal(
|
||||
(ref) => create(ref as SongsListRef),
|
||||
from: from,
|
||||
name: null,
|
||||
dependencies: null,
|
||||
allTransitiveDependencies: null,
|
||||
debugGetCreateSourceHash: null,
|
||||
opt: opt,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
@override
|
||||
AutoDisposeFutureProviderElement<List<Song>> createElement() {
|
||||
return _SongsListProviderElement(this);
|
||||
}
|
||||
|
||||
@override
|
||||
bool operator ==(Object other) {
|
||||
return other is SongsListProvider && other.opt == opt;
|
||||
@@ -108,4 +140,18 @@ class SongsListProvider extends AutoDisposeFutureProvider<List<Song>> {
|
||||
return _SystemHash.finish(hash);
|
||||
}
|
||||
}
|
||||
// ignore_for_file: unnecessary_raw_strings, subtype_of_sealed_class, invalid_use_of_internal_member, do_not_use_environment, prefer_const_constructors, public_member_api_docs, avoid_private_typedef_functions
|
||||
|
||||
mixin SongsListRef on AutoDisposeFutureProviderRef<List<Song>> {
|
||||
/// The parameter `opt` of this provider.
|
||||
ListQuery get opt;
|
||||
}
|
||||
|
||||
class _SongsListProviderElement
|
||||
extends AutoDisposeFutureProviderElement<List<Song>> with SongsListRef {
|
||||
_SongsListProviderElement(super.provider);
|
||||
|
||||
@override
|
||||
ListQuery get opt => (origin as SongsListProvider).opt;
|
||||
}
|
||||
// ignore_for_file: type=lint
|
||||
// ignore_for_file: subtype_of_sealed_class, invalid_use_of_internal_member, invalid_use_of_visible_for_testing_member
|
||||
|
||||
@@ -55,13 +55,13 @@ class NowPlayingPage extends HookConsumerWidget {
|
||||
],
|
||||
),
|
||||
),
|
||||
body: Stack(
|
||||
body: const Stack(
|
||||
children: [
|
||||
const MediaItemGradient(),
|
||||
MediaItemGradient(),
|
||||
Padding(
|
||||
padding: const EdgeInsets.symmetric(horizontal: 8, vertical: 8),
|
||||
padding: EdgeInsets.symmetric(horizontal: 8, vertical: 8),
|
||||
child: Column(
|
||||
children: const [
|
||||
children: [
|
||||
Expanded(
|
||||
child: Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: 16),
|
||||
@@ -229,8 +229,8 @@ class _Progress extends HookConsumerWidget {
|
||||
value: changing.value ? changeValue.value : position.toDouble(),
|
||||
min: 0,
|
||||
max: max(duration.toDouble(), position.toDouble()),
|
||||
thumbColor: colors?.theme.colorScheme.onBackground,
|
||||
activeColor: colors?.theme.colorScheme.onBackground,
|
||||
thumbColor: colors?.theme.colorScheme.surface,
|
||||
activeColor: colors?.theme.colorScheme.surface,
|
||||
inactiveColor: colors?.theme.colorScheme.surface,
|
||||
onChanged: (value) {
|
||||
changeValue.value = value;
|
||||
@@ -354,7 +354,7 @@ class _Controls extends HookConsumerWidget {
|
||||
final audio = ref.watch(audioControlProvider);
|
||||
|
||||
return IconTheme(
|
||||
data: IconThemeData(color: base.theme.colorScheme.onBackground),
|
||||
data: IconThemeData(color: base.theme.colorScheme.surface),
|
||||
child: Column(
|
||||
children: [
|
||||
SizedBox(
|
||||
|
||||
@@ -35,4 +35,5 @@ final searchQueryProvider =
|
||||
);
|
||||
|
||||
typedef _$SearchQuery = AutoDisposeNotifier<String?>;
|
||||
// ignore_for_file: unnecessary_raw_strings, subtype_of_sealed_class, invalid_use_of_internal_member, do_not_use_environment, prefer_const_constructors, public_member_api_docs, avoid_private_typedef_functions
|
||||
// ignore_for_file: type=lint
|
||||
// ignore_for_file: subtype_of_sealed_class, invalid_use_of_internal_member, invalid_use_of_visible_for_testing_member
|
||||
|
||||
@@ -191,7 +191,7 @@ class _ShareLogsButton extends StatelessWidget {
|
||||
final files = await logFiles();
|
||||
if (files.isEmpty) return;
|
||||
|
||||
// ignore: use_build_context_synchronously
|
||||
if (!context.mounted) return;
|
||||
final value = await showDialog<String>(
|
||||
context: context,
|
||||
builder: (context) => MultipleChoiceDialog<String>(
|
||||
|
||||
@@ -76,8 +76,8 @@ class SourcePage extends HookConsumerWidget {
|
||||
onChanged: (value) => forcePlaintextPassword.value = value,
|
||||
);
|
||||
|
||||
return WillPopScope(
|
||||
onWillPop: () async => !isSaving.value && !isDeleting.value,
|
||||
return PopScope(
|
||||
canPop: !isSaving.value && !isDeleting.value,
|
||||
child: Scaffold(
|
||||
appBar: AppBar(),
|
||||
floatingActionButton: Row(
|
||||
@@ -164,6 +164,7 @@ class SourcePage extends HookConsumerWidget {
|
||||
);
|
||||
}
|
||||
} catch (e, st) {
|
||||
if (!context.mounted) return;
|
||||
showErrorSnackbar(context, e.toString());
|
||||
log.severe('Saving source', e, st);
|
||||
error = true;
|
||||
|
||||
Reference in New Issue
Block a user