From 8854c401a9bf5dfb66c7a6ff7811fa3f1f3a1f24 Mon Sep 17 00:00:00 2001 From: Tarasov Aleksandr <55220741+arabianq@users.noreply.github.com> Date: Thu, 30 Jul 2026 10:36:57 +0300 Subject: [PATCH] fix(gui): add translation for "No tracks playing" (#181) --- pwsp-gui/locales/app.toml | 11 +++++++++++ pwsp-gui/src/gui/views/header.rs | 3 ++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/pwsp-gui/locales/app.toml b/pwsp-gui/locales/app.toml index 027a395..c6b4876 100644 --- a/pwsp-gui/locales/app.toml +++ b/pwsp-gui/locales/app.toml @@ -4,6 +4,17 @@ _version = 2 # Main page # ---------------- +[gui.no_tracks_playing] +en = "No tracks playing" +ru = "Не запущено ни одного трека" +es = "No hay pistas en reproducción" +fr = "Aucune piste en cours de lecture" +zh = "没有正在播放的曲目" +ar = "لا يوجد مسارات قيد التشغيل" +kz = "Ешқандай трек ойнатылып жатқан жоқ" +he = "אין רצועות שמנוגנות" +pt-BR = "Nenhuma faixa reproduzindo" + [gui.play_file_button] en = "Play file" ru = "Выбрать файл" diff --git a/pwsp-gui/src/gui/views/header.rs b/pwsp-gui/src/gui/views/header.rs index 8b0c10d..363ce71 100644 --- a/pwsp-gui/src/gui/views/header.rs +++ b/pwsp-gui/src/gui/views/header.rs @@ -3,6 +3,7 @@ use egui::{Button, CollapsingHeader, FontFamily, Label, RichText, Slider, Ui}; use egui_material_icons::icons::*; use pwsp_lib::types::{audio_player::TrackInfo, gui::AppState}; use pwsp_lib::utils::gui::format_time_pair; +use rust_i18n::t; pub(crate) enum TrackAction { Pause(u32), @@ -15,7 +16,7 @@ impl SoundpadGui { pub fn draw_header(&mut self, ui: &mut Ui) { ui.vertical_centered_justified(|ui| { if self.audio_player_state.tracks.is_empty() { - ui.label("No tracks playing"); + ui.label(t!("gui.no_tracks_playing")); return; }