-
Notifications
You must be signed in to change notification settings - Fork 91
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'space-sunrise:master' into DOUBLE-LANG-FIX
- Loading branch information
Showing
1,508 changed files
with
966,037 additions
and
12,645 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -13,13 +13,9 @@ jobs: | |
runs-on: ubuntu-latest | ||
steps: | ||
- uses: actions/[email protected] | ||
- name: Setup Submodule | ||
run: git submodule update --init | ||
- name: Pull engine updates | ||
uses: space-wizards/[email protected] | ||
- uses: PaulRitter/yaml-schema-validator@v1 | ||
with: | ||
schema: RobustToolbox/Schemas/rga.yml | ||
schema: Tools/Schemas/rga.yml | ||
path_pattern: .*attributions.ya?ml$ | ||
validators_path: RobustToolbox/Schemas/rga_validators.py | ||
validators_requirements: RobustToolbox/Schemas/rga_requirements.txt | ||
validators_path: Tools/Schemas/rga_validators.py | ||
validators_requirements: Tools/Schemas/rga_requirements.txt |
16 changes: 11 additions & 5 deletions
16
Content.Client/Administration/UI/Tabs/ObjectsTab/ObjectsTab.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,21 @@ | ||
<Control xmlns="https://spacestation14.io" | ||
xmlns:cc="clr-namespace:Content.Client.Administration.UI.CustomControls"> | ||
xmlns:cc="clr-namespace:Content.Client.Administration.UI.CustomControls" | ||
xmlns:ot="clr-namespace:Content.Client.Administration.UI.Tabs.ObjectsTab" | ||
xmlns:co="clr-namespace:Content.Client.UserInterface.Controls"> | ||
<BoxContainer Orientation="Vertical"> | ||
<BoxContainer Orientation="Horizontal"> | ||
<Label HorizontalExpand="True" SizeFlagsStretchRatio="0.50" | ||
Text="{Loc Object type:}" /> | ||
<LineEdit Name="SearchLineEdit" PlaceHolder="{Loc Search...}" HorizontalExpand="True" SizeFlagsStretchRatio="1"/> | ||
<OptionButton Name="ObjectTypeOptions" HorizontalExpand="True" SizeFlagsStretchRatio="0.25"/> | ||
</BoxContainer> | ||
<BoxContainer Orientation="Horizontal" HorizontalExpand="True"> | ||
</BoxContainer> | ||
<cc:HSeparator/> | ||
<ScrollContainer HorizontalExpand="True" VerticalExpand="True"> | ||
<BoxContainer Orientation="Vertical" Name="ObjectList"> | ||
</BoxContainer> | ||
</ScrollContainer> | ||
<BoxContainer Orientation="Vertical" HorizontalExpand="True" VerticalExpand="True"> | ||
<ot:ObjectsTabHeader Name="ListHeader"/> | ||
<cc:HSeparator/> | ||
<co:SearchListContainer Name="SearchList" Access="Public" VerticalExpand="True"/> | ||
</BoxContainer> | ||
</BoxContainer> | ||
</Control> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 4 additions & 2 deletions
6
Content.Client/Administration/UI/Tabs/ObjectsTab/ObjectsTabEntry.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,21 @@ | ||
using Robust.Client.AutoGenerated; | ||
using Robust.Client.Graphics; | ||
using Robust.Client.UserInterface.Controls; | ||
using Robust.Client.UserInterface.XAML; | ||
|
||
namespace Content.Client.Administration.UI.Tabs.ObjectsTab; | ||
|
||
[GenerateTypedNameReferences] | ||
public sealed partial class ObjectsTabEntry : ContainerButton | ||
public sealed partial class ObjectsTabEntry : PanelContainer | ||
{ | ||
public NetEntity AssocEntity; | ||
|
||
public ObjectsTabEntry(string name, NetEntity nent) | ||
public ObjectsTabEntry(string name, NetEntity nent, StyleBox styleBox) | ||
{ | ||
RobustXamlLoader.Load(this); | ||
AssocEntity = nent; | ||
EIDLabel.Text = nent.ToString(); | ||
NameLabel.Text = name; | ||
BackgroundColorPanel.PanelOverride = styleBox; | ||
} | ||
} |
21 changes: 21 additions & 0 deletions
21
Content.Client/Administration/UI/Tabs/ObjectsTab/ObjectsTabHeader.xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
<Control xmlns="https://spacestation14.io" | ||
xmlns:cc="clr-namespace:Content.Client.Administration.UI.CustomControls"> | ||
<PanelContainer Name="BackgroundColorPanel" Access="Public"/> | ||
<BoxContainer Orientation="Horizontal" | ||
HorizontalExpand="True" | ||
SeparationOverride="4"> | ||
<Label Name="ObjectNameLabel" | ||
SizeFlagsStretchRatio="3" | ||
HorizontalExpand="True" | ||
ClipText="True" | ||
Text="{Loc object-tab-object-name}" | ||
MouseFilter="Pass"/> | ||
<cc:VSeparator/> | ||
<Label Name="EntityIDLabel" | ||
SizeFlagsStretchRatio="3" | ||
HorizontalExpand="True" | ||
ClipText="True" | ||
Text="{Loc object-tab-entity-id}" | ||
MouseFilter="Pass"/> | ||
</BoxContainer> | ||
</Control> |
86 changes: 86 additions & 0 deletions
86
Content.Client/Administration/UI/Tabs/ObjectsTab/ObjectsTabHeader.xaml.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,86 @@ | ||
using Robust.Client.AutoGenerated; | ||
using Robust.Client.UserInterface; | ||
using Robust.Client.UserInterface.Controls; | ||
using Robust.Client.UserInterface.XAML; | ||
using Robust.Shared.Input; | ||
|
||
namespace Content.Client.Administration.UI.Tabs.ObjectsTab | ||
{ | ||
[GenerateTypedNameReferences] | ||
public sealed partial class ObjectsTabHeader : Control | ||
{ | ||
public event Action<Header>? OnHeaderClicked; | ||
|
||
private const string ArrowUp = "↑"; | ||
private const string ArrowDown = "↓"; | ||
|
||
public ObjectsTabHeader() | ||
{ | ||
RobustXamlLoader.Load(this); | ||
|
||
ObjectNameLabel.OnKeyBindDown += ObjectNameClicked; | ||
EntityIDLabel.OnKeyBindDown += EntityIDClicked; | ||
} | ||
|
||
public Label GetHeader(Header header) | ||
{ | ||
return header switch | ||
{ | ||
Header.ObjectName => ObjectNameLabel, | ||
Header.EntityID => EntityIDLabel, | ||
_ => throw new ArgumentOutOfRangeException(nameof(header), header, null) | ||
}; | ||
} | ||
|
||
public void ResetHeaderText() | ||
{ | ||
ObjectNameLabel.Text = Loc.GetString("object-tab-object-name"); | ||
EntityIDLabel.Text = Loc.GetString("object-tab-entity-id"); | ||
} | ||
|
||
public void UpdateHeaderSymbols(Header headerClicked, bool ascending) | ||
{ | ||
ResetHeaderText(); | ||
var arrow = ascending ? ArrowUp : ArrowDown; | ||
GetHeader(headerClicked).Text += $" {arrow}"; | ||
} | ||
|
||
private void HeaderClicked(GUIBoundKeyEventArgs args, Header header) | ||
{ | ||
if (args.Function != EngineKeyFunctions.UIClick) | ||
{ | ||
return; | ||
} | ||
|
||
OnHeaderClicked?.Invoke(header); | ||
args.Handle(); | ||
} | ||
|
||
private void ObjectNameClicked(GUIBoundKeyEventArgs args) | ||
{ | ||
HeaderClicked(args, Header.ObjectName); | ||
} | ||
|
||
private void EntityIDClicked(GUIBoundKeyEventArgs args) | ||
{ | ||
HeaderClicked(args, Header.EntityID); | ||
} | ||
|
||
protected override void Dispose(bool disposing) | ||
{ | ||
base.Dispose(disposing); | ||
|
||
if (disposing) | ||
{ | ||
ObjectNameLabel.OnKeyBindDown -= ObjectNameClicked; | ||
EntityIDLabel.OnKeyBindDown -= EntityIDClicked; | ||
} | ||
} | ||
|
||
public enum Header | ||
{ | ||
ObjectName, | ||
EntityID | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.