From 0fa617a09eedf6bdb25eda55fac1d3344859fd93 Mon Sep 17 00:00:00 2001
From: yyl <yyl>
Date: 星期二, 31 三月 2026 19:46:31 +0800
Subject: [PATCH] webgl

---
 Main/Utility/ComponentExtersion.cs |    8 +++++++-
 1 files changed, 7 insertions(+), 1 deletions(-)

diff --git a/Main/Utility/ComponentExtersion.cs b/Main/Utility/ComponentExtersion.cs
index a162fd7..128d639 100644
--- a/Main/Utility/ComponentExtersion.cs
+++ b/Main/Utility/ComponentExtersion.cs
@@ -539,11 +539,17 @@
             return;
         }
 
+        _image.enabled = false;
+
         UILoader.LoadTexture2DPNGAsync(_id).ContinueWith(texture =>
         {
-            if (_image != null && texture != null)
+            if (_image == null) return;
+
+            if (texture != null)
             {
                 _image.texture = texture;
+                _image.SetNativeSize();
+                _image.enabled = true;
             }
         }).Forget();
     }

--
Gitblit v1.8.0