diff --git a/Content.Client/ADT/Economy/ATMVisualLayers.cs b/Content.Client/ADT/Economy/ATMVisualLayers.cs new file mode 100644 index 0000000000..b559aae509 --- /dev/null +++ b/Content.Client/ADT/Economy/ATMVisualLayers.cs @@ -0,0 +1,7 @@ +namespace Content.Client.ADT.Economy; + +public enum ATMVisualLayers : byte +{ + Base, + BaseUnshaded +} diff --git a/Content.Client/ADT/Economy/UI/ATMBui.cs b/Content.Client/ADT/Economy/UI/ATMBui.cs new file mode 100644 index 0000000000..462d976cd6 --- /dev/null +++ b/Content.Client/ADT/Economy/UI/ATMBui.cs @@ -0,0 +1,42 @@ +using JetBrains.Annotations; + +namespace Content.Client.ADT.Economy.UI; + + +[UsedImplicitly] +public sealed class ATMBui : BoundUserInterface +{ + private AtmWindow _window; + + public ATMBui(EntityUid owner, Enum uiKey) : base(owner, uiKey) + { + _window = new AtmWindow(); + } + + protected override void Open() + { + base.Open(); + _window.OnClose += Close; + _window.OnWithdrawAttempt += SendMessage; + + if (State != null) + { + UpdateState(State); + } + + _window.OpenCentered(); + + } + + protected override void UpdateState(BoundUserInterfaceState state) + { + base.UpdateState(state); + _window?.UpdateState(state); + } + + protected override void Dispose(bool disposing) + { + _window?.Close(); + base.Dispose(disposing); + } +} diff --git a/Content.Client/ADT/Economy/UI/AtmWindow.xaml b/Content.Client/ADT/Economy/UI/AtmWindow.xaml new file mode 100644 index 0000000000..a2a32b316a --- /dev/null +++ b/Content.Client/ADT/Economy/UI/AtmWindow.xaml @@ -0,0 +1,20 @@ + + + + +