Files
RobustToolbox/Robust.Client/UserInterface/LocExtension.cs
2022-02-05 19:31:58 +01:00

24 lines
547 B
C#

using JetBrains.Annotations;
using Robust.Shared.Localization;
namespace Robust.Client.UserInterface
{
// TODO: Code a XAML compiler transformer to remove references to this type at compile time.
// And just replace them with the Loc.GetString() call.
[PublicAPI]
public sealed class LocExtension
{
public string Key { get; }
public LocExtension(string key)
{
Key = key;
}
public object ProvideValue()
{
return Loc.GetString(Key);
}
}
}