diff --git a/src/ExplorerCore.cs b/src/ExplorerCore.cs index bdbe5ec..8df1c05 100644 --- a/src/ExplorerCore.cs +++ b/src/ExplorerCore.cs @@ -20,7 +20,7 @@ namespace UnityExplorer public static class ExplorerCore { public const string NAME = "UnityExplorer"; - public const string VERSION = "4.1.0"; + public const string VERSION = "4.1.1"; public const string AUTHOR = "Sinai"; public const string GUID = "com.sinai.unityexplorer"; diff --git a/src/UI/Inspectors/ReflectionInspector.cs b/src/UI/Inspectors/ReflectionInspector.cs index 69b0b12..881105e 100644 --- a/src/UI/Inspectors/ReflectionInspector.cs +++ b/src/UI/Inspectors/ReflectionInspector.cs @@ -617,12 +617,15 @@ namespace UnityExplorer.UI.Inspectors // Actual texture viewer - var imageObj = UIFactory.CreateUIObject("TextureViewerImage", textureViewer); - textureImage = imageObj.AddComponent(); - textureImageLayout = textureImage.gameObject.AddComponent(); + var imageViewport = UIFactory.CreateVerticalGroup(textureViewer, "Viewport", false, false, true, true); + imageViewport.GetComponent().color = Color.white; + imageViewport.AddComponent().showMaskGraphic = false; + var imageObj = UIFactory.CreateUIObject("Image", imageViewport); var fitter = imageObj.AddComponent(); fitter.verticalFit = ContentSizeFitter.FitMode.PreferredSize; + textureImage = imageObj.AddComponent(); + textureImageLayout = UIFactory.SetLayoutElement(imageObj, flexibleWidth: 9999, flexibleHeight: 9999); textureViewer.SetActive(false); }