mirror of
https://github.com/space-syndicate/space-station-14.git
synced 2026-10-09 10:21:18 +03:00
* Initial commit * refactor: cleanup of related code --------- Co-authored-by: Fildrance <fildrance@gmail.com>
31 lines
927 B
C#
31 lines
927 B
C#
using Content.Shared.CCVar;
|
|
using Robust.Client.AutoGenerated;
|
|
using Robust.Client.UserInterface;
|
|
using Robust.Client.UserInterface.CustomControls;
|
|
using Robust.Client.UserInterface.XAML;
|
|
using Robust.Shared.Configuration;
|
|
|
|
namespace Content.Client.Options.UI;
|
|
|
|
[GenerateTypedNameReferences]
|
|
public sealed partial class EscapeMenu : DefaultWindow
|
|
{
|
|
public EscapeMenu()
|
|
{
|
|
RobustXamlLoader.Load(this);
|
|
|
|
// TODO: removed with https://github.com/space-wizards/space-station-14/pull/44431
|
|
var uriOpener = IoCManager.Resolve<IUriOpener>();
|
|
var cfg = IoCManager.Resolve<IConfigurationManager>();
|
|
|
|
var bugReport = cfg.GetCVar(CCVars.InfoLinksBugReport);
|
|
if (!string.IsNullOrWhiteSpace(bugReport))
|
|
{
|
|
BugReportButton.OnPressed += _ => uriOpener.OpenUri(bugReport);
|
|
}
|
|
else
|
|
{
|
|
BugReportButton.Visible = false;
|
|
}
|
|
}
|
|
}
|