From 9f7d2583a3be763b13ce1e0d91c33708f4cb5c16 Mon Sep 17 00:00:00 2001 From: monitor1394 Date: Tue, 17 Sep 2019 18:39:01 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0AnimationEnabel()=E5=90=AF?= =?UTF-8?q?=E7=94=A8=E6=88=96=E5=8F=96=E6=B6=88=E8=B5=B7=E5=A7=8B=E5=8A=A8?= =?UTF-8?q?=E7=94=BB=E6=8E=A5=E5=8F=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Scripts/UI/Component/Series.cs | 11 +++++++++++ Scripts/UI/Internal/BaseChart_API.cs | 16 ++++++++++++++-- 2 files changed, 25 insertions(+), 2 deletions(-) diff --git a/Scripts/UI/Component/Series.cs b/Scripts/UI/Component/Series.cs index c6a72c36..6f9f8343 100644 --- a/Scripts/UI/Component/Series.cs +++ b/Scripts/UI/Component/Series.cs @@ -795,6 +795,17 @@ namespace XCharts } } + /// + /// 启用或取消初始动画 + /// + public void AnimationEnable(bool flag) + { + foreach (var serie in m_Series) + { + serie.animation.enable = flag; + } + } + /// /// 开始初始动画 /// diff --git a/Scripts/UI/Internal/BaseChart_API.cs b/Scripts/UI/Internal/BaseChart_API.cs index a129170e..039b7ff7 100644 --- a/Scripts/UI/Internal/BaseChart_API.cs +++ b/Scripts/UI/Internal/BaseChart_API.cs @@ -424,7 +424,18 @@ namespace XCharts } /// - /// 开始初始动画 + /// Whether series animation enabel. + /// 启用或取消起始动画。 + /// + /// + public void AnimationEnable(bool flag) + { + m_Series.AnimationEnable(flag); + } + + /// + /// Start play animation. + /// 开始初始动画。 /// public void AnimationStart() { @@ -432,7 +443,8 @@ namespace XCharts } /// - /// 停止初始化动画 + /// Stop play animation. + /// 停止初始化动画。 /// public void AnimationStop() {