-
Notifications
You must be signed in to change notification settings - Fork 47
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
6 changed files
with
90 additions
and
10 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
<Control xmlns="https://spacestation14.io"> | ||
<BoxContainer Orientation="Horizontal"> | ||
<PanelContainer Name="Background" | ||
Access="Public" | ||
StyleClasses="PdaBackground" | ||
VerticalExpand="False" | ||
HorizontalExpand="False" | ||
MaxWidth="10" | ||
Margin="0 0 -5 0"/> | ||
<Button Name="Main" | ||
Disabled="True" | ||
HorizontalExpand="True" | ||
VerticalExpand="False" | ||
StyleClasses="ButtonSquare" | ||
Margin="0" | ||
ToolTip="foobar"> | ||
<BoxContainer Orientation="Horizontal" Margin="0"> | ||
<Control MinWidth="5"/> | ||
<RichTextLabel Name="NameLabel" StyleClasses="LabelSubText" VerticalAlignment="Center"/> | ||
</BoxContainer> | ||
</Button> | ||
</BoxContainer> | ||
</Control> |
28 changes: 28 additions & 0 deletions
28
Content.Client/ADT/Research/UI/MiniRecipeCardControl.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,28 @@ | ||
using Content.Shared.Research.Prototypes; | ||
using Robust.Client.AutoGenerated; | ||
using Robust.Client.GameObjects; | ||
using Robust.Client.UserInterface; | ||
using Robust.Client.UserInterface.CustomControls; | ||
using Robust.Client.UserInterface.XAML; | ||
using Robust.Shared.Prototypes; | ||
using Robust.Shared.Utility; | ||
|
||
namespace Content.Client.ADT.Research.UI; | ||
|
||
[GenerateTypedNameReferences] | ||
public sealed partial class MiniRecipeCardControl : Control | ||
{ | ||
public MiniRecipeCardControl(TechnologyPrototype technology, string name, IPrototypeManager prototypeManager) | ||
{ | ||
RobustXamlLoader.Load(this); | ||
|
||
var discipline = prototypeManager.Index(technology.Discipline); | ||
Background.ModulateSelfOverride = discipline.Color; | ||
NameLabel.SetMessage(Loc.GetString(technology.Name)); | ||
|
||
// var tooltip = new Tooltip(); | ||
// tooltip.SetMessage(description); | ||
// Main.TooltipSupplier = _ => tooltip; | ||
// Technology = technology; | ||
} | ||
} |
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
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