Add panic bunker toggle to admin menu (#13450)
This commit is contained in:
@@ -5,9 +5,9 @@
|
||||
MinSize="50 50">
|
||||
<GridContainer
|
||||
Columns="4" >
|
||||
<cc:CommandButton Command="restart" Text="{Loc server-reboot}" />
|
||||
<cc:CommandButton Command="shutdown" Text="{Loc server-shutdown}" />
|
||||
<cc:CommandButton Name="SetOocButton" Command="setooc" Text="{Loc server-ooc-toggle}" ToggleMode="True" />
|
||||
<cc:CommandButton Name="SetLoocButton" Command="setlooc" Text="{Loc server-looc-toggle}" ToggleMode="True" />
|
||||
<cc:CommandButton Name="SetPanicbunkerButton" Command="panicbunker" Text="{Loc server-panicbunker-toggle}" ToggleMode="True" />
|
||||
</GridContainer>
|
||||
</Control>
|
||||
|
||||
@@ -18,6 +18,7 @@ namespace Content.Client.Administration.UI.Tabs
|
||||
|
||||
_config.OnValueChanged(CCVars.OocEnabled, OocEnabledChanged, true);
|
||||
_config.OnValueChanged(CCVars.LoocEnabled, LoocEnabledChanged, true);
|
||||
_config.OnValueChanged(CCVars.PanicBunkerEnabled, BunkerEnabledChanged, true);
|
||||
}
|
||||
|
||||
private void OocEnabledChanged(bool value)
|
||||
@@ -30,6 +31,11 @@ namespace Content.Client.Administration.UI.Tabs
|
||||
SetLoocButton.Pressed = value;
|
||||
}
|
||||
|
||||
private void BunkerEnabledChanged(bool value)
|
||||
{
|
||||
SetPanicbunkerButton.Pressed = value;
|
||||
}
|
||||
|
||||
protected override void Dispose(bool disposing)
|
||||
{
|
||||
base.Dispose(disposing);
|
||||
@@ -38,6 +44,7 @@ namespace Content.Client.Administration.UI.Tabs
|
||||
{
|
||||
_config.UnsubValueChanged(CCVars.OocEnabled, OocEnabledChanged);
|
||||
_config.UnsubValueChanged(CCVars.LoocEnabled, LoocEnabledChanged);
|
||||
_config.UnsubValueChanged(CCVars.PanicBunkerEnabled, BunkerEnabledChanged);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user