Minamp 1.5: Galician interface

- Interface in Galician by default regardless of the phone's language, with
  English selectable under Axustes -> Idioma; switching rebuilds the screens
- All text in tools/strings.py (key -> English, Galician), generating
  res/values/strings.xml (gl) and res/values-en/strings.xml; layouts now use
  string resources
- util/Tr.java: translations for the network and Plex layers, which can't
  read Android resources (falls back to English in desktop tests)
- net/RefusedException: distinguish "server answered but refused" from
  connection failures
- The connection log stays in English for troubleshooting

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
xockoandClaude Opus 5.5 committed 2026-10-15 00:11:41 +02:00
1 parent 6fd17bc9c5
commit fa67e95fde
29 files changed
+1029 -206

No files matched your search

+9 -8
View File
@@ -87,7 +87,7 @@ public class NowPlayingActivity extends BaseActivity {
public void onClick(View v) {
PlayQueue.get().cycleRepeat();
int r = PlayQueue.get().repeat();
toast(r == PlayQueue.REPEAT_ALL ? "Repeat queue" : r == PlayQueue.REPEAT_ONE ? "Repeat track" : "Repeat off");
toast(str(r == PlayQueue.REPEAT_ALL ? R.string.repeat_queue : r == PlayQueue.REPEAT_ONE ? R.string.repeat_track : R.string.repeat_off));
}
});
loveGlyph = Ui.glyph(this, Glyph.HEART_OUTLINE, white, 20); loveGlyph.scale(1f);
@@ -153,8 +153,8 @@ public class NowPlayingActivity extends BaseActivity {
Item it = PlayQueue.get().current();
PlayQueue q = PlayQueue.get();
if (it == null) {
title.setText("Nothing playing");
sub.setText("Pick something from your library");
title.setText(R.string.nothing_playing);
sub.setText(R.string.pick_something);
from.setText("");
art.setImageResource(R.drawable.art_placeholder);
shownThumb = null;
@@ -170,7 +170,7 @@ public class NowPlayingActivity extends BaseActivity {
loveGlyph.setType(it.loved() ? Glyph.HEART : Glyph.HEART_OUTLINE);
loveGlyph.setColor(it.loved() ? accent : white);
albumLink.setVisibility(it.albumKey.length() > 0 ? View.VISIBLE : View.INVISIBLE);
albumLink.setText("Album ›");
albumLink.setText(R.string.album_link);
if (!it.thumb.equals(shownThumb)) {
shownThumb = it.thumb;
@@ -203,9 +203,9 @@ public class NowPlayingActivity extends BaseActivity {
private void updateSleep() {
long at = PlayerService.sleepAt();
if (PlayerService.sleepEndOfTrack()) sleepText.setText("End of track");
if (PlayerService.sleepEndOfTrack()) sleepText.setText(R.string.end_of_track);
else if (at > 0) sleepText.setText(Ui.time(at - System.currentTimeMillis()));
else sleepText.setText("Sleep");
else sleepText.setText(R.string.sleep);
}
private void setBackdrop(int color) {
@@ -216,8 +216,9 @@ public class NowPlayingActivity extends BaseActivity {
private void sleepDialog() {
final int[] mins = {0, 15, 30, 45, 60, 90, -1};
String[] labels = {"Off", "15 minutes", "30 minutes", "45 minutes", "1 hour", "1½ hours", "End of this track"};
new AlertDialog.Builder(this).setTitle("Sleep timer")
String[] labels = {str(R.string.sleep_off), str(R.string.sleep_15), str(R.string.sleep_30), str(R.string.sleep_45),
str(R.string.sleep_60), str(R.string.sleep_90), str(R.string.sleep_eot)};
new AlertDialog.Builder(this).setTitle(R.string.sleep_timer)
.setItems(labels, new DialogInterface.OnClickListener() {
public void onClick(DialogInterface d, int which) {
startService(new Intent(NowPlayingActivity.this, PlayerService.class)