From c65cf5bb1f8ea4236c6f44d9c3414c1b0b0aed22 Mon Sep 17 00:00:00 2001 From: ike709 Date: Sat, 23 Jul 2022 18:58:28 -0700 Subject: [PATCH] Adds the station name to PDAs (#9987) Co-authored-by: ike709 --- Content.Client/PDA/PDABoundUserInterface.cs | 6 +++-- Content.Client/PDA/PDAMenu.xaml | 5 +++- Content.Server/PDA/PDASystem.cs | 25 +++++++++++++++++--- Content.Shared/PDA/PDAComponent.cs | 1 + Content.Shared/PDA/PDAUpdateState.cs | 4 +++- Resources/Locale/en-US/pda/pda-component.ftl | 6 +++++ 6 files changed, 40 insertions(+), 7 deletions(-) diff --git a/Content.Client/PDA/PDABoundUserInterface.cs b/Content.Client/PDA/PDABoundUserInterface.cs index 48edfecf2c..818e8247fc 100644 --- a/Content.Client/PDA/PDABoundUserInterface.cs +++ b/Content.Client/PDA/PDABoundUserInterface.cs @@ -79,14 +79,16 @@ namespace Content.Client.PDA if (msg.PDAOwnerInfo.IdOwner != null || msg.PDAOwnerInfo.JobTitle != null) { _menu.IdInfoLabel.SetMarkup(Loc.GetString("comp-pda-ui", - ("Owner",msg.PDAOwnerInfo.IdOwner ?? "Unknown"), - ("JobTitle",msg.PDAOwnerInfo.JobTitle ?? "Unassigned"))); + ("Owner",msg.PDAOwnerInfo.IdOwner ?? Loc.GetString("comp-pda-ui-unknown")), + ("JobTitle",msg.PDAOwnerInfo.JobTitle ?? Loc.GetString("comp-pda-ui-unassigned")))); } else { _menu.IdInfoLabel.SetMarkup(Loc.GetString("comp-pda-ui-blank")); } + _menu.StationNameLabel.SetMarkup(Loc.GetString("comp-pda-ui-station", ("Station",msg.StationName ?? Loc.GetString("comp-pda-ui-unknown")))); + _menu.EjectIdButton.Visible = msg.PDAOwnerInfo.IdOwner != null || msg.PDAOwnerInfo.JobTitle != null; _menu.EjectPenButton.Visible = msg.HasPen; _menu.ActivateUplinkButton.Visible = msg.HasUplink; diff --git a/Content.Client/PDA/PDAMenu.xaml b/Content.Client/PDA/PDAMenu.xaml index 40c31b9b2d..e17c2416c8 100644 --- a/Content.Client/PDA/PDAMenu.xaml +++ b/Content.Client/PDA/PDAMenu.xaml @@ -8,9 +8,12 @@ HorizontalExpand="True" MinSize="50 50"> + -