Rename Fluent *GetString methods to GetMessage.

This commit is contained in:
Paul Chote
2024-10-19 13:09:40 +01:00
committed by Gustas
parent 09063d23da
commit 67254e0b39
104 changed files with 396 additions and 396 deletions

View File

@@ -167,7 +167,7 @@ namespace OpenRA.Mods.Common.Widgets
public void Do()
{
editorActorPreview = editorLayer.Add(actor);
Text = FluentProvider.GetString(AddedActor,
Text = FluentProvider.GetMessage(AddedActor,
"name", editorActorPreview.Info.Name,
"id", editorActorPreview.ID);
}

View File

@@ -146,7 +146,7 @@ namespace OpenRA.Mods.Common.Widgets
undoClipboard = CopySelectionContents();
Text = FluentProvider.GetString(CopiedTiles, "amount", clipboard.Tiles.Count);
Text = FluentProvider.GetMessage(CopiedTiles, "amount", clipboard.Tiles.Count);
}
/// <summary>

View File

@@ -308,15 +308,15 @@ namespace OpenRA.Mods.Common.Widgets
};
if (selection.Area != null)
Text = FluentProvider.GetString(SelectedArea,
Text = FluentProvider.GetMessage(SelectedArea,
"x", selection.Area.TopLeft.X,
"y", selection.Area.TopLeft.Y,
"width", selection.Area.BottomRight.X - selection.Area.TopLeft.X,
"height", selection.Area.BottomRight.Y - selection.Area.TopLeft.Y);
else if (selection.Actor != null)
Text = FluentProvider.GetString(SelectedActor, "id", selection.Actor.ID);
Text = FluentProvider.GetMessage(SelectedActor, "id", selection.Actor.ID);
else
Text = FluentProvider.GetString(ClearedSelection);
Text = FluentProvider.GetMessage(ClearedSelection);
}
public void Execute()
@@ -360,7 +360,7 @@ namespace OpenRA.Mods.Common.Widgets
Actor = defaultBrush.Selection.Actor
};
Text = FluentProvider.GetString(RemovedActor, "name", actor.Info.Name, "id", actor.ID);
Text = FluentProvider.GetMessage(RemovedActor, "name", actor.Info.Name, "id", actor.ID);
}
public void Execute()
@@ -396,7 +396,7 @@ namespace OpenRA.Mods.Common.Widgets
this.editorActorLayer = editorActorLayer;
this.actor = actor;
Text = FluentProvider.GetString(RemovedActor, "name", actor.Info.Name, "id", actor.ID);
Text = FluentProvider.GetMessage(RemovedActor, "name", actor.Info.Name, "id", actor.ID);
}
public void Execute()
@@ -464,7 +464,7 @@ namespace OpenRA.Mods.Common.Widgets
to = worldRenderer.Viewport.ViewToWorld(pixelTo + pixelOffset) + cellOffset;
layer.MoveActor(actor, to);
Text = FluentProvider.GetString(MovedActor, "id", actor.ID, "x1", from.X, "y1", from.Y, "x2", to.X, "y2", to.Y);
Text = FluentProvider.GetMessage(MovedActor, "id", actor.ID, "x1", from.X, "y1", from.Y, "x2", to.X, "y2", to.Y);
}
}
@@ -485,7 +485,7 @@ namespace OpenRA.Mods.Common.Widgets
this.resourceLayer = resourceLayer;
this.cell = cell;
Text = FluentProvider.GetString(RemovedResource, "type", resourceType);
Text = FluentProvider.GetMessage(RemovedResource, "type", resourceType);
}
public void Execute()

View File

@@ -150,9 +150,9 @@ namespace OpenRA.Mods.Common.Widgets
}
if (type != null)
Text = FluentProvider.GetString(AddedMarkerTiles, "amount", paintTiles.Count, "type", type);
Text = FluentProvider.GetMessage(AddedMarkerTiles, "amount", paintTiles.Count, "type", type);
else
Text = FluentProvider.GetString(RemovedMarkerTiles, "amount", paintTiles.Count);
Text = FluentProvider.GetMessage(RemovedMarkerTiles, "amount", paintTiles.Count);
}
}
@@ -176,7 +176,7 @@ namespace OpenRA.Mods.Common.Widgets
tiles = new HashSet<CPos>(markerLayerOverlay.Tiles[tile]);
Text = FluentProvider.GetString(ClearedSelectedMarkerTiles, "amount", tiles.Count, "type", tile);
Text = FluentProvider.GetMessage(ClearedSelectedMarkerTiles, "amount", tiles.Count, "type", tile);
}
public void Execute()
@@ -213,7 +213,7 @@ namespace OpenRA.Mods.Common.Widgets
var allTilesCount = tiles.Values.Select(x => x.Count).Sum();
Text = FluentProvider.GetString(ClearedAllMarkerTiles, "amount", allTilesCount);
Text = FluentProvider.GetMessage(ClearedAllMarkerTiles, "amount", allTilesCount);
}
public void Execute()

View File

@@ -168,7 +168,7 @@ namespace OpenRA.Mods.Common.Widgets
resourceLayer.ClearResources(resourceCell.Cell);
resourceLayer.AddResource(resourceCell.NewResourceType, resourceCell.Cell, resourceLayer.GetMaxDensity(resourceCell.NewResourceType));
cellResources.Add(resourceCell);
Text = FluentProvider.GetString(AddedResource, "amount", cellResources.Count, "type", resourceType);
Text = FluentProvider.GetMessage(AddedResource, "amount", cellResources.Count, "type", resourceType);
}
}
}

View File

@@ -192,7 +192,7 @@ namespace OpenRA.Mods.Common.Widgets
var terrainInfo = (ITemplatedTerrainInfo)map.Rules.TerrainInfo;
terrainTemplate = terrainInfo.Templates[template];
Text = FluentProvider.GetString(AddedTile, "id", terrainTemplate.Id);
Text = FluentProvider.GetMessage(AddedTile, "id", terrainTemplate.Id);
}
public void Execute()
@@ -264,7 +264,7 @@ namespace OpenRA.Mods.Common.Widgets
var terrainInfo = (ITemplatedTerrainInfo)map.Rules.TerrainInfo;
terrainTemplate = terrainInfo.Templates[template];
Text = FluentProvider.GetString(FilledTile, "id", terrainTemplate.Id);
Text = FluentProvider.GetMessage(FilledTile, "id", terrainTemplate.Id);
}
public void Execute()