[NUI] Make Selector implements IEnumerable instead ICollection
authorJiyun Yang <ji.yang@samsung.com>
Fri, 9 Apr 2021 08:24:18 +0000 (17:24 +0900)
committerhuiyueun <35286162+huiyueun@users.noreply.github.com>
Tue, 20 Apr 2021 06:13:00 +0000 (15:13 +0900)
Signed-off-by: Jiyun Yang <ji.yang@samsung.com>
src/Tizen.NUI.Components/Controls/Button.Internal.cs
src/Tizen.NUI/src/public/BaseComponents/Style/Selector.cs

index 883bf2e..dd4814e 100755 (executable)
@@ -287,7 +287,7 @@ namespace Tizen.NUI.Components
         [EditorBrowsable(EditorBrowsableState.Never)]
         public override void OnRelayout(Vector2 size, RelayoutContainer container)
         {
-            Debug.Assert(size != null);
+            if (size == null) return;
 
             if (size.Equals(this.size))
             {
index 81b932e..b91b74d 100755 (executable)
@@ -32,7 +32,7 @@ namespace Tizen.NUI.BaseComponents
                      "CA1710:IdentifiersShouldHaveCorrectSuffix",
                      Justification = "The name Selector provides meaningful information about the characteristics.")]
     [EditorBrowsable(EditorBrowsableState.Never)]
-    public class Selector<T> : ICollection<SelectorItem<T>>
+    public class Selector<T> : IEnumerable<SelectorItem<T>>
     {
         private readonly bool cloneable = typeof(ICloneable).IsAssignableFrom(typeof(T));
         private SelectorItem<T> all;