Rename Fluent-related code to be more precise.
This commit is contained in:
@@ -35,37 +35,37 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
"StatisticsArmyGraphKey")]
|
||||
public class ObserverStatsLogic : ChromeLogic
|
||||
{
|
||||
[TranslationReference]
|
||||
[FluentReference]
|
||||
const string InformationNone = "options-observer-stats.none";
|
||||
|
||||
[TranslationReference]
|
||||
[FluentReference]
|
||||
const string Basic = "options-observer-stats.basic";
|
||||
|
||||
[TranslationReference]
|
||||
[FluentReference]
|
||||
const string Economy = "options-observer-stats.economy";
|
||||
|
||||
[TranslationReference]
|
||||
[FluentReference]
|
||||
const string Production = "options-observer-stats.production";
|
||||
|
||||
[TranslationReference]
|
||||
[FluentReference]
|
||||
const string SupportPowers = "options-observer-stats.support-powers";
|
||||
|
||||
[TranslationReference]
|
||||
[FluentReference]
|
||||
const string Combat = "options-observer-stats.combat";
|
||||
|
||||
[TranslationReference]
|
||||
[FluentReference]
|
||||
const string Army = "options-observer-stats.army";
|
||||
|
||||
[TranslationReference]
|
||||
[FluentReference]
|
||||
const string EarningsGraph = "options-observer-stats.earnings-graph";
|
||||
|
||||
[TranslationReference]
|
||||
[FluentReference]
|
||||
const string ArmyGraph = "options-observer-stats.army-graph";
|
||||
|
||||
[TranslationReference("team")]
|
||||
[FluentReference("team")]
|
||||
const string TeamNumber = "label-team-name";
|
||||
|
||||
[TranslationReference]
|
||||
[FluentReference]
|
||||
const string NoTeam = "label-no-team";
|
||||
|
||||
readonly ContainerWidget basicStatsHeaders;
|
||||
@@ -155,10 +155,10 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
var statsDropDown = widget.Get<DropDownButtonWidget>("STATS_DROPDOWN");
|
||||
StatsDropDownOption CreateStatsOption(string title, ObserverStatsPanel panel, ScrollItemWidget template, Action a)
|
||||
{
|
||||
title = TranslationProvider.GetString(title);
|
||||
title = FluentProvider.GetString(title);
|
||||
return new StatsDropDownOption
|
||||
{
|
||||
Title = TranslationProvider.GetString(title),
|
||||
Title = FluentProvider.GetString(title),
|
||||
IsSelected = () => activePanel == panel,
|
||||
OnClick = () =>
|
||||
{
|
||||
@@ -179,11 +179,11 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
{
|
||||
new()
|
||||
{
|
||||
Title = TranslationProvider.GetString(InformationNone),
|
||||
Title = FluentProvider.GetString(InformationNone),
|
||||
IsSelected = () => activePanel == ObserverStatsPanel.None,
|
||||
OnClick = () =>
|
||||
{
|
||||
var informationNone = TranslationProvider.GetString(InformationNone);
|
||||
var informationNone = FluentProvider.GetString(InformationNone);
|
||||
statsDropDown.GetText = () => informationNone;
|
||||
playerStatsPanel.Visible = false;
|
||||
ClearStats();
|
||||
@@ -286,8 +286,8 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
tt.IgnoreMouseOver = true;
|
||||
|
||||
var teamLabel = tt.Get<LabelWidget>("TEAM");
|
||||
var teamText = team.Key > 0 ? TranslationProvider.GetString(TeamNumber, Translation.Arguments("team", team.Key))
|
||||
: TranslationProvider.GetString(NoTeam);
|
||||
var teamText = team.Key > 0 ? FluentProvider.GetString(TeamNumber, FluentBundle.Arguments("team", team.Key))
|
||||
: FluentProvider.GetString(NoTeam);
|
||||
teamLabel.GetText = () => teamText;
|
||||
tt.Bounds.Width = teamLabel.Bounds.Width = Game.Renderer.Fonts[tt.Font].Measure(teamText).X;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user