Files
tbd-station-14/Content.Client/Traitor/Uplink/UplinkListingControl.xaml.cs
Alex Evgrashin 4002aa5852 Uplink UI icons and withdraw button (#4929)
* Uplink menu has icons now

* Add item icons

* Add few descriptions

* Better withdraw window

* Finished with withdraw window

* Refactored withdraw ui and fix some bugs

* Basic withdraw

* Quick fixes

* Removed uplink listing for TCs

* Move slider to separate control

* Final touches

* A bit more

* Not again...

* Fixed names

* Address review

* Fixed robust

* Non necessary check
2021-10-29 11:40:47 +02:00

29 lines
831 B
C#

using Robust.Client.AutoGenerated;
using Robust.Client.Graphics;
using Robust.Client.UserInterface;
using Robust.Client.UserInterface.Controls;
using Robust.Client.UserInterface.XAML;
using Robust.Shared.Maths;
namespace Content.Client.Traitor.Uplink
{
[GenerateTypedNameReferences]
public partial class UplinkListingControl : Control
{
public UplinkListingControl(string itemName, string itemDescription,
int itemPrice, bool canBuy, Texture? texture = null)
{
RobustXamlLoader.Load(this);
UplinkItemName.Text = itemName;
UplinkItemDescription.SetMessage(itemDescription);
UplinkItemBuyButton.Text = $"{itemPrice} TC";
UplinkItemBuyButton.Disabled = !canBuy;
UplinkItemTexture.Texture = texture;
}
}
}