From dac09679a52b4bffa3769424e5659b5a9b121816 Mon Sep 17 00:00:00 2001 From: Plykiya <58439124+Plykiya@users.noreply.github.com> Date: Fri, 28 Jun 2024 14:21:36 -0700 Subject: [PATCH] Fixes Chameleon menu icons appearing incorrectly (#29539) EntityPrototypeView my beloved Co-authored-by: plykiya --- Content.Client/Clothing/UI/ChameleonMenu.xaml.cs | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) 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); } } -- 2.51.2