This commit is contained in:
rang 2026-01-04 17:49:05 +08:00
parent a737365f26
commit 3c3c381f8a
18 changed files with 1266 additions and 1000 deletions

View file

@ -51,7 +51,7 @@ class PlayerSettings with _$PlayerSettings {
ExpandedPlayerSettings expandedPlayerSettings,
@Default(1) double preferredDefaultVolume,
@Default(1) double preferredDefaultSpeed,
@Default([1, 1.25, 1.5, 1.75, 2]) List<double> speedOptions,
@Default([0.5, 0.75, 1, 1.25, 1.5, 1.75, 2]) List<double> speedOptions,
@Default(0.05) double speedIncrement,
@Default(0.1) double minSpeed,
@Default(4) double maxSpeed,

View file

@ -986,7 +986,15 @@ class _$PlayerSettingsImpl implements _PlayerSettings {
this.expandedPlayerSettings = const ExpandedPlayerSettings(),
this.preferredDefaultVolume = 1,
this.preferredDefaultSpeed = 1,
final List<double> speedOptions = const [1, 1.25, 1.5, 1.75, 2],
final List<double> speedOptions = const [
0.5,
0.75,
1,
1.25,
1.5,
1.75,
2
],
this.speedIncrement = 0.05,
this.minSpeed = 0.1,
this.maxSpeed = 4,

View file

@ -99,7 +99,7 @@ _$PlayerSettingsImpl _$$PlayerSettingsImplFromJson(Map<String, dynamic> json) =>
speedOptions: (json['speedOptions'] as List<dynamic>?)
?.map((e) => (e as num).toDouble())
.toList() ??
const [1, 1.25, 1.5, 1.75, 2],
const [0.5, 0.75, 1, 1.25, 1.5, 1.75, 2],
speedIncrement: (json['speedIncrement'] as num?)?.toDouble() ?? 0.05,
minSpeed: (json['minSpeed'] as num?)?.toDouble() ?? 0.1,
maxSpeed: (json['maxSpeed'] as num?)?.toDouble() ?? 4,