Rename Fluent-related code to be more precise.

This commit is contained in:
Paul Chote
2024-10-01 19:34:12 +01:00
committed by Gustas
parent 771b9ddfda
commit b29b685058
176 changed files with 1349 additions and 1369 deletions

View File

@@ -19,16 +19,16 @@ namespace OpenRA.Mods.Common.Widgets.Logic
{
public class GameTimerLogic : ChromeLogic
{
[TranslationReference]
[FluentReference]
const string Paused = "label-paused";
[TranslationReference]
[FluentReference]
const string MaxSpeed = "label-max-speed";
[TranslationReference("percentage")]
[FluentReference("percentage")]
const string Speed = "label-replay-speed";
[TranslationReference("percentage")]
[FluentReference("percentage")]
const string Complete = "label-replay-complete";
[ObjectCreator.UseCtor]
@@ -44,10 +44,10 @@ namespace OpenRA.Mods.Common.Widgets.Logic
bool Paused() => world.Paused || world.ReplayTimestep == 0;
var pausedText = TranslationProvider.GetString(GameTimerLogic.Paused);
var maxSpeedText = TranslationProvider.GetString(MaxSpeed);
var pausedText = FluentProvider.GetString(GameTimerLogic.Paused);
var maxSpeedText = FluentProvider.GetString(MaxSpeed);
var speedText = new CachedTransform<int, string>(p =>
TranslationProvider.GetString(Speed, Translation.Arguments("percentage", p)));
FluentProvider.GetString(Speed, FluentBundle.Arguments("percentage", p)));
if (timer != null)
{
@@ -79,7 +79,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic
}
var timerText = new CachedTransform<int, string>(p =>
TranslationProvider.GetString(Complete, Translation.Arguments("percentage", p)));
FluentProvider.GetString(Complete, FluentBundle.Arguments("percentage", p)));
if (timer is LabelWithTooltipWidget timerTooltip)
{
var connection = orderManager.Connection as ReplayConnection;