Add an option to order maps by size
This commit is contained in:
@@ -72,6 +72,9 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
|||||||
[TranslationReference]
|
[TranslationReference]
|
||||||
const string OrderMapsByDate = "options-order-maps.date";
|
const string OrderMapsByDate = "options-order-maps.date";
|
||||||
|
|
||||||
|
[TranslationReference]
|
||||||
|
const string OrderMapsBySize = "options-order-maps.size";
|
||||||
|
|
||||||
readonly string allMaps;
|
readonly string allMaps;
|
||||||
|
|
||||||
readonly Widget widget;
|
readonly Widget widget;
|
||||||
@@ -292,6 +295,7 @@ namespace OpenRA.Mods.Common.Widgets.Logic
|
|||||||
{ orderByPlayer, m => m.PlayerCount },
|
{ orderByPlayer, m => m.PlayerCount },
|
||||||
{ TranslationProvider.GetString(OrderMapsByTitle), null },
|
{ TranslationProvider.GetString(OrderMapsByTitle), null },
|
||||||
{ TranslationProvider.GetString(OrderMapsByDate), m => -m.ModifiedDate.Ticks },
|
{ TranslationProvider.GetString(OrderMapsByDate), m => -m.ModifiedDate.Ticks },
|
||||||
|
{ TranslationProvider.GetString(OrderMapsBySize), m => m.Bounds.Width * m.Bounds.Height },
|
||||||
};
|
};
|
||||||
|
|
||||||
orderByFunc = orderByDict[orderByPlayer];
|
orderByFunc = orderByDict[orderByPlayer];
|
||||||
|
|||||||
@@ -469,6 +469,7 @@ options-order-maps =
|
|||||||
.player-count = Players
|
.player-count = Players
|
||||||
.title = Title
|
.title = Title
|
||||||
.date = Date
|
.date = Date
|
||||||
|
.size = Size
|
||||||
|
|
||||||
## MissionBrowserLogic
|
## MissionBrowserLogic
|
||||||
dialog-no-video =
|
dialog-no-video =
|
||||||
|
|||||||
Reference in New Issue
Block a user