From 8dda8c8ff347fb6aecc11a4c32bc7c4a6f5f333f Mon Sep 17 00:00:00 2001 From: ww-rm Date: Sun, 23 Mar 2025 10:58:57 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0=E5=8A=A8=E7=94=BB=E4=BA=A4?= =?UTF-8?q?=E9=9B=86=E9=80=89=E6=8B=A9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- SpineViewer/Spine/TypeConverter.cs | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/SpineViewer/Spine/TypeConverter.cs b/SpineViewer/Spine/TypeConverter.cs index 88a84d5..5dc3c21 100644 --- a/SpineViewer/Spine/TypeConverter.cs +++ b/SpineViewer/Spine/TypeConverter.cs @@ -42,7 +42,19 @@ namespace SpineViewer.Spine public override StandardValuesCollection? GetStandardValues(ITypeDescriptorContext? context) { if (context?.Instance is Spine obj) + { return new StandardValuesCollection(obj.AnimationNames); + } + else if (context?.Instance is Spine[] spines) + { + if (spines.Length > 0) + { + IEnumerable common = spines[0].AnimationNames; + foreach (var spine in spines.Skip(1)) + common = common.Intersect(spine.AnimationNames); + return new StandardValuesCollection(common.ToArray()); + } + } return base.GetStandardValues(context); } }