From d3a52f3fe6cfa405f1414fd556152015c23a9b07 Mon Sep 17 00:00:00 2001 From: "everLEEst(SangHyeon Lee)" Date: Fri, 13 May 2022 02:32:53 -0700 Subject: [PATCH] [NUI] fix warnings. add null argument exception and comments. --- src/Tizen.NUI.Components/Controls/ScrollableBase.cs | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/Tizen.NUI.Components/Controls/ScrollableBase.cs b/src/Tizen.NUI.Components/Controls/ScrollableBase.cs index e478e55..6cba3ea 100755 --- a/src/Tizen.NUI.Components/Controls/ScrollableBase.cs +++ b/src/Tizen.NUI.Components/Controls/ScrollableBase.cs @@ -27,8 +27,11 @@ namespace Tizen.NUI.Components /// ScrollEventArgs is a class to record scroll event arguments which will sent to user. /// /// 8 + [global::System.Diagnostics.CodeAnalysis.SuppressMessage("Design", "CA1001: Types that own disposable fields should be disposable.", Justification = "Scroll event is temporarily used for notifying scroll position update, so position will not be disposed during the event processing.")] public class ScrollEventArgs : EventArgs { + // Position class is derived class of Disposable class and they will be implicitly disposed by DisposeQueue, + // so that there will be no memory leak. private Position position; private Position scrollPosition; @@ -1720,6 +1723,7 @@ namespace Tizen.NUI.Components [EditorBrowsable(EditorBrowsableState.Never)] protected virtual void Decelerating(float velocity, Animation animation) { + if (animation == null) throw new ArgumentNullException(nameof(animation)); // Decelerating using deceleration equation =========== // // V : velocity (pixel per millisecond) -- 2.7.4