From: Plykiya <58439124+Plykiya@users.noreply.github.com> Date: Fri, 28 Jun 2024 21:21:36 +0000 (-0700) Subject: Fixes Chameleon menu icons appearing incorrectly (#29539) X-Git-Url: https://git.smokeofanarchy.ru/gitweb.cgi?a=commitdiff_plain;h=dac09679a52b4bffa3769424e5659b5a9b121816;p=space-station-14.git Fixes Chameleon menu icons appearing incorrectly (#29539) EntityPrototypeView my beloved Co-authored-by: plykiya --- diff --git a/Content.Client/Clothing/UI/ChameleonMenu.xaml.cs b/Content.Client/Clothing/UI/ChameleonMenu.xaml.cs index 131ee3b1e9..4532484d8a 100644 --- a/Content.Client/Clothing/UI/ChameleonMenu.xaml.cs +++ b/Content.Client/Clothing/UI/ChameleonMenu.xaml.cs @@ -1,4 +1,4 @@ -using System.Linq; +using System.Linq; using System.Numerics; using Content.Client.Clothing.Systems; using Content.Client.Stylesheets; @@ -74,13 +74,9 @@ public sealed partial class ChameleonMenu : DefaultWindow }; button.OnPressed += _ => OnIdSelected?.Invoke(id); Grid.AddChild(button); - - var texture = _sprite.GetPrototypeIcon(proto); - button.AddChild(new TextureRect - { - Stretch = TextureRect.StretchMode.KeepAspectCentered, - Texture = texture.Default - }); + var entityPrototypeView = new EntityPrototypeView(); + entityPrototypeView.SetPrototype(proto); + button.AddChild(entityPrototypeView); } }