Remove FluentBundle.Arguments helper method.
This commit is contained in:
@@ -171,7 +171,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
|
||||
var displaySelectionDropDown = panel.Get<DropDownButtonWidget>("DISPLAY_SELECTION_DROPDOWN");
|
||||
displaySelectionDropDown.OnMouseDown = _ => ShowDisplaySelectionDropdown(displaySelectionDropDown, ds);
|
||||
var displaySelectionLabel = new CachedTransform<int, string>(i => FluentProvider.GetString(Display, FluentBundle.Arguments("number", i + 1)));
|
||||
var displaySelectionLabel = new CachedTransform<int, string>(i => FluentProvider.GetString(Display, "number", i + 1));
|
||||
displaySelectionDropDown.GetText = () => displaySelectionLabel.Update(ds.VideoDisplay);
|
||||
displaySelectionDropDown.IsDisabled = () => Game.Renderer.DisplayCount < 2;
|
||||
|
||||
@@ -242,7 +242,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
|
||||
var frameLimitGamespeedCheckbox = panel.Get<CheckboxWidget>("FRAME_LIMIT_GAMESPEED_CHECKBOX");
|
||||
var frameLimitCheckbox = panel.Get<CheckboxWidget>("FRAME_LIMIT_CHECKBOX");
|
||||
var frameLimitLabel = new CachedTransform<int, string>(fps => FluentProvider.GetString(FrameLimiter, FluentBundle.Arguments("fps", fps)));
|
||||
var frameLimitLabel = new CachedTransform<int, string>(fps => FluentProvider.GetString(FrameLimiter, "fps", fps));
|
||||
frameLimitCheckbox.GetText = () => frameLimitLabel.Update(ds.MaxFramerate);
|
||||
frameLimitCheckbox.IsDisabled = () => ds.CapFramerateToGameFps;
|
||||
|
||||
|
||||
@@ -229,16 +229,16 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
duplicateNotice.IsVisible = () => !isHotkeyValid;
|
||||
var duplicateNoticeText = new CachedTransform<HotkeyDefinition, string>(hd =>
|
||||
hd != null ?
|
||||
FluentProvider.GetString(DuplicateNotice, FluentBundle.Arguments("key", hd.Description,
|
||||
"context", hd.Contexts.First(c => selectedHotkeyDefinition.Contexts.Contains(c)))) :
|
||||
"");
|
||||
FluentProvider.GetString(DuplicateNotice,
|
||||
"key", hd.Description,
|
||||
"context", hd.Contexts.First(c => selectedHotkeyDefinition.Contexts.Contains(c))) : "");
|
||||
duplicateNotice.GetText = () => duplicateNoticeText.Update(duplicateHotkeyDefinition);
|
||||
|
||||
var originalNotice = panel.Get<LabelWidget>("ORIGINAL_NOTICE");
|
||||
originalNotice.TextColor = ChromeMetrics.Get<Color>("NoticeInfoColor");
|
||||
originalNotice.IsVisible = () => isHotkeyValid && !isHotkeyDefault;
|
||||
var originalNoticeText = new CachedTransform<HotkeyDefinition, string>(hd =>
|
||||
FluentProvider.GetString(OriginalNotice, FluentBundle.Arguments("key", hd?.Default.DisplayString())));
|
||||
FluentProvider.GetString(OriginalNotice, "key", hd?.Default.DisplayString()));
|
||||
originalNotice.GetText = () => originalNoticeText.Update(selectedHotkeyDefinition);
|
||||
|
||||
var readonlyNotice = panel.Get<LabelWidget>("READONLY_NOTICE");
|
||||
|
||||
@@ -143,7 +143,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
||||
ConfirmationDialogs.ButtonPrompt(modData,
|
||||
title: ResetTitle,
|
||||
text: ResetPrompt,
|
||||
titleArguments: FluentBundle.Arguments("panel", panels[activePanel]),
|
||||
titleArguments: new object[] { "panel", panels[activePanel] },
|
||||
onConfirm: Reset,
|
||||
confirmText: ResetAccept,
|
||||
onCancel: () => { },
|
||||
|
||||
Reference in New Issue
Block a user