added missing translation
This commit is contained in:
parent
1e3034fa52
commit
5411d47924
4 changed files with 22 additions and 21 deletions
|
@ -2,6 +2,7 @@
|
||||||
|
|
||||||
- Fixed bug in "Append to manually queued songs"
|
- Fixed bug in "Append to manually queued songs"
|
||||||
- Fixed bug in queue when moving a song directly before the currently playing song
|
- Fixed bug in queue when moving a song directly before the currently playing song
|
||||||
|
- Added German translation (#51)
|
||||||
|
|
||||||
## 1.2.0
|
## 1.2.0
|
||||||
|
|
||||||
|
|
|
@ -24,6 +24,25 @@ extension PlayableTextExtension on PlayableType {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
extension PlayableReprExt on Playable {
|
||||||
|
String repr(BuildContext context) {
|
||||||
|
switch (type) {
|
||||||
|
case PlayableType.all:
|
||||||
|
return L10n.of(context)!.allSongs;
|
||||||
|
case PlayableType.album:
|
||||||
|
return '${L10n.of(context)!.album}: $title';
|
||||||
|
case PlayableType.artist:
|
||||||
|
return '${L10n.of(context)!.artist}: $title';
|
||||||
|
case PlayableType.playlist:
|
||||||
|
return '${L10n.of(context)!.playlist}: $title';
|
||||||
|
case PlayableType.smartlist:
|
||||||
|
return '${L10n.of(context)!.smartlist}: $title';
|
||||||
|
case PlayableType.search:
|
||||||
|
return '${L10n.of(context)!.search}: $title';
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
extension OrderCriterionExtension on OrderCriterion {
|
extension OrderCriterionExtension on OrderCriterion {
|
||||||
String toText(BuildContext context) {
|
String toText(BuildContext context) {
|
||||||
switch (this) {
|
switch (this) {
|
||||||
|
|
|
@ -62,7 +62,7 @@ class QueuePage extends StatelessWidget {
|
||||||
|
|
||||||
if (playable != null) {
|
if (playable != null) {
|
||||||
subTitle = Text(
|
subTitle = Text(
|
||||||
playable.repr(),
|
playable.repr(context),
|
||||||
maxLines: 1,
|
maxLines: 1,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|
|
@ -89,25 +89,6 @@ Color linkColor(Song song) {
|
||||||
return Colors.white24;
|
return Colors.white24;
|
||||||
}
|
}
|
||||||
|
|
||||||
extension PlayableReprExt on Playable {
|
|
||||||
String repr() {
|
|
||||||
switch (type) {
|
|
||||||
case PlayableType.all:
|
|
||||||
return 'All songs';
|
|
||||||
case PlayableType.album:
|
|
||||||
return 'Album: $title';
|
|
||||||
case PlayableType.artist:
|
|
||||||
return 'Artist: $title';
|
|
||||||
case PlayableType.playlist:
|
|
||||||
return 'Playlist: $title';
|
|
||||||
case PlayableType.smartlist:
|
|
||||||
return 'Smartlist: $title';
|
|
||||||
case PlayableType.search:
|
|
||||||
return 'Search results: $title';
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
Widget createPlayableCover(Playable playable, double size) {
|
Widget createPlayableCover(Playable playable, double size) {
|
||||||
switch (playable.type) {
|
switch (playable.type) {
|
||||||
case PlayableType.all:
|
case PlayableType.all:
|
||||||
|
@ -149,4 +130,4 @@ Widget createPlayableCover(Playable playable, double size) {
|
||||||
icon: Icons.search_rounded,
|
icon: Icons.search_rounded,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue