upload
This commit is contained in:
commit
1c7a8cf25f
579 files changed
+83196
No files matched your search
@@ -0,0 +1,23 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
|
||||
namespace VibranceHud.Presets;
|
||||
|
||||
public static class PresetLibrary
|
||||
{
|
||||
public const string Everything = "All";
|
||||
|
||||
public static readonly IReadOnlyList<LibraryPreset> All = Array.Empty<LibraryPreset>();
|
||||
|
||||
public static IReadOnlyList<string> Games => new string[1] { "All" }.Concat(All.Select((LibraryPreset p) => p.Game).Distinct()).ToList();
|
||||
|
||||
public static IReadOnlyList<LibraryPreset> ForGame(string game)
|
||||
{
|
||||
if (!string.Equals(game, "All", StringComparison.OrdinalIgnoreCase))
|
||||
{
|
||||
return All.Where((LibraryPreset p) => string.Equals(p.Game, game, StringComparison.OrdinalIgnoreCase)).ToList();
|
||||
}
|
||||
return All;
|
||||
}
|
||||
}
|
||||
Reference in new issue
Block a user