From e77e08c0494e517558b30cd7a4ecd46dc8a4ce54 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=D0=91=D0=BE=D1=82=D0=BD=D0=B8=D0=BA=D0=BE=D0=B2=20=D0=9C?= =?UTF-8?q?=D0=B0=D0=BA=D1=81=D0=B8=D0=BC?= Date: Fri, 6 Feb 2026 15:22:06 +0500 Subject: [PATCH] Localize "Effect, Master, Music" in `VolumeOverlay` (#36594) --- osu.Game/Overlays/Volume/MasterVolumeMeter.cs | 3 ++- osu.Game/Overlays/Volume/VolumeMeter.cs | 5 +++-- osu.Game/Overlays/VolumeOverlay.cs | 8 +++++--- 3 files changed, 10 insertions(+), 6 deletions(-) diff --git a/osu.Game/Overlays/Volume/MasterVolumeMeter.cs b/osu.Game/Overlays/Volume/MasterVolumeMeter.cs index 951a6d53b1..fd3d410321 100644 --- a/osu.Game/Overlays/Volume/MasterVolumeMeter.cs +++ b/osu.Game/Overlays/Volume/MasterVolumeMeter.cs @@ -5,6 +5,7 @@ using osu.Framework.Allocation; using osu.Framework.Audio; using osu.Framework.Bindables; using osu.Framework.Graphics; +using osu.Framework.Localisation; using osuTK.Graphics; namespace osu.Game.Overlays.Volume @@ -20,7 +21,7 @@ namespace osu.Game.Overlays.Volume [Resolved] private VolumeOverlay volumeOverlay { get; set; } = null!; - public MasterVolumeMeter(string name, float circleSize, Color4 meterColour) + public MasterVolumeMeter(LocalisableString name, float circleSize, Color4 meterColour) : base(name, circleSize, meterColour) { } diff --git a/osu.Game/Overlays/Volume/VolumeMeter.cs b/osu.Game/Overlays/Volume/VolumeMeter.cs index ed9c5c13ef..ec3d897a63 100644 --- a/osu.Game/Overlays/Volume/VolumeMeter.cs +++ b/osu.Game/Overlays/Volume/VolumeMeter.cs @@ -19,6 +19,7 @@ using osu.Framework.Graphics.Effects; using osu.Framework.Graphics.Shapes; using osu.Framework.Graphics.UserInterface; using osu.Framework.Input.Events; +using osu.Framework.Localisation; using osu.Framework.Threading; using osu.Framework.Utils; using osu.Game.Graphics; @@ -42,7 +43,7 @@ namespace osu.Game.Overlays.Volume protected readonly float CircleSize; private readonly Color4 meterColour; - private readonly string name; + private readonly LocalisableString name; private OsuSpriteText text; private BufferedContainer maxGlow; @@ -75,7 +76,7 @@ namespace osu.Game.Overlays.Volume private const float transition_length = 500; - public VolumeMeter(string name, float circleSize, Color4 meterColour) + public VolumeMeter(LocalisableString name, float circleSize, Color4 meterColour) { CircleSize = circleSize; this.meterColour = meterColour; diff --git a/osu.Game/Overlays/VolumeOverlay.cs b/osu.Game/Overlays/VolumeOverlay.cs index bb2ad60695..8a656f4f24 100644 --- a/osu.Game/Overlays/VolumeOverlay.cs +++ b/osu.Game/Overlays/VolumeOverlay.cs @@ -6,6 +6,7 @@ using osu.Framework.Allocation; using osu.Framework.Audio; using osu.Framework.Bindables; using osu.Framework.Extensions.Color4Extensions; +using osu.Framework.Extensions.LocalisationExtensions; using osu.Framework.Graphics; using osu.Framework.Graphics.Colour; using osu.Framework.Graphics.Containers; @@ -15,6 +16,7 @@ using osu.Framework.Threading; using osu.Game.Graphics; using osu.Game.Graphics.Containers; using osu.Game.Input.Bindings; +using osu.Game.Localisation; using osu.Game.Overlays.Volume; using osuTK; using osuTK.Graphics; @@ -67,9 +69,9 @@ namespace osu.Game.Overlays Spacing = new Vector2(0, offset), Children = new[] { - volumeMeterEffect = new VolumeMeter("EFFECTS", 125, colours.BlueDarker), - volumeMeterMaster = new MasterVolumeMeter("MASTER", 150, colours.PinkDarker) { IsMuted = { BindTarget = IsMuted }, }, - volumeMeterMusic = new VolumeMeter("MUSIC", 125, colours.BlueDarker), + volumeMeterEffect = new VolumeMeter(AudioSettingsStrings.EffectVolume.ToUpper(), 125, colours.BlueDarker), + volumeMeterMaster = new MasterVolumeMeter(AudioSettingsStrings.MasterVolume.ToUpper(), 150, colours.PinkDarker) { IsMuted = { BindTarget = IsMuted }, }, + volumeMeterMusic = new VolumeMeter(AudioSettingsStrings.MusicVolume.ToUpper(), 125, colours.BlueDarker), } }, },