Merge remote-tracking branch 'origin/master' into tizen
authoradmin <tizenapi@samsung.com>
Mon, 29 Jun 2020 15:51:50 +0000 (15:51 +0000)
committeradmin <tizenapi@samsung.com>
Mon, 29 Jun 2020 15:51:50 +0000 (15:51 +0000)
13 files changed:
src/Tizen.NUI.Components/Controls/FlexibleView/FlexibleView.cs
src/Tizen.NUI.Components/Controls/FlexibleView/FlexibleViewLayoutManager.cs
src/Tizen.NUI.Components/Controls/FlexibleView/GridLayoutManager.cs
src/Tizen.NUI.Components/Controls/FlexibleView/LinearLayoutManager.Internal.cs
src/Tizen.NUI.Components/Controls/FlexibleView/LinearLayoutManager.cs
src/Tizen.NUI.Components/Controls/ImageScrollBar.cs
src/Tizen.NUI.Components/Controls/RecyclerView/GridRecycleLayoutManager.cs
src/Tizen.NUI.Components/Controls/RecyclerView/LinearRecycleLayoutManager.cs
src/Tizen.NUI.Components/Controls/RecyclerView/RecycleLayoutManager.cs
src/Tizen.NUI.Components/Controls/RecyclerView/RecyclerView.cs
src/Tizen.NUI.Components/Style/ImageScrollBarStyle.cs
src/Tizen.NUI.Wearable/src/internal/FishEyeLayoutManager.cs
src/Tizen.NUI.Wearable/src/public/WearableList.cs

index 1ee4aad..5f2df59 100755 (executable)
@@ -449,7 +449,7 @@ namespace Tizen.NUI.Components
                 if (mLayout != null)
                 {
                     mLayout.StopScroll(false);
-                    mLayout.Dispose();
+                    mLayout.ClearRecyclerView();
                     mLayout = null;
                 }
 
index b22a1e4..26b66f9 100755 (executable)
@@ -739,6 +739,12 @@ namespace Tizen.NUI.Components
             mChildHelper = recyclerView.GetChildHelper();
         }
 
+        internal void ClearRecyclerView()
+        {
+            mFlexibleView = null;
+            mChildHelper = null;
+        }
+
         internal void StopScroll(bool doSomethingAfterAnimationStopped)
         {
             if (mScrollAni != null && mScrollAni.State == Animation.States.Playing)
index 330561c..ae00bfc 100755 (executable)
@@ -88,7 +88,7 @@ namespace Tizen.NUI.Components
         [EditorBrowsable(EditorBrowsableState.Never)]
         protected override int GetNextPosition(int position, FlexibleViewLayoutManager.Direction direction)
         {
-            if (mOrientation == HORIZONTAL)
+            if (Orientation == HORIZONTAL)
             {
                 switch (direction)
                 {
@@ -176,7 +176,7 @@ namespace Tizen.NUI.Components
                 result.Consumed = mOrientationHelper.GetViewHolderMeasurement(holder);
 
                 float left, top, width, height;
-                if (mOrientation == VERTICAL)
+                if (Orientation == VERTICAL)
                 {
                     width = (Width - PaddingLeft - PaddingRight) / count;
                     height = result.Consumed;
index d10bc14..88375d2 100755 (executable)
@@ -26,7 +26,7 @@ namespace Tizen.NUI.Components
             result.Consumed = mOrientationHelper.GetViewHolderMeasurement(holder);
 
             float left, top, width, height;
-            if (mOrientation == VERTICAL)
+            if (Orientation == VERTICAL)
             {
                 width = Width - PaddingLeft - PaddingRight;
                 height = result.Consumed;
@@ -180,16 +180,16 @@ namespace Tizen.NUI.Components
             switch (focusDirection)
             {
                 case FlexibleViewLayoutManager.Direction.Up:
-                    return mOrientation == VERTICAL ? LayoutState.LAYOUT_START
+                    return Orientation == VERTICAL ? LayoutState.LAYOUT_START
                             : LayoutState.INVALID_LAYOUT;
                 case FlexibleViewLayoutManager.Direction.Down:
-                    return mOrientation == VERTICAL ? LayoutState.LAYOUT_END
+                    return Orientation == VERTICAL ? LayoutState.LAYOUT_END
                             : LayoutState.INVALID_LAYOUT;
                 case FlexibleViewLayoutManager.Direction.Left:
-                    return mOrientation == HORIZONTAL ? LayoutState.LAYOUT_START
+                    return Orientation == HORIZONTAL ? LayoutState.LAYOUT_START
                             : LayoutState.INVALID_LAYOUT;
                 case FlexibleViewLayoutManager.Direction.Right:
-                    return mOrientation == HORIZONTAL ? LayoutState.LAYOUT_END
+                    return Orientation == HORIZONTAL ? LayoutState.LAYOUT_END
                             : LayoutState.INVALID_LAYOUT;
                 default:
                     return LayoutState.INVALID_LAYOUT;
index ba6eba0..901a037 100755 (executable)
@@ -57,14 +57,6 @@ namespace Tizen.NUI.Components
 
         private const float MAX_SCROLL_FACTOR = 1 / 3f;
 
-        /// <summary>
-        /// Current orientation.
-        /// </summary>
-        /// <since_tizen> 6 </since_tizen>
-        /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API.
-        [EditorBrowsable(EditorBrowsableState.Never)]
-        protected int mOrientation;
-
         internal OrientationHelper mOrientationHelper;
 
         private LayoutState mLayoutState;
@@ -92,14 +84,22 @@ namespace Tizen.NUI.Components
         [EditorBrowsable(EditorBrowsableState.Never)]
         public LinearLayoutManager(int orientation)
         {
-            mOrientation = orientation;
-            mOrientationHelper = OrientationHelper.CreateOrientationHelper(this, mOrientation);
+            Orientation = orientation;
+            mOrientationHelper = OrientationHelper.CreateOrientationHelper(this, Orientation);
 
             mLayoutState = new LayoutState();
             mLayoutState.Offset = mOrientationHelper.GetStartAfterPadding();
         }
 
         /// <summary>
+        /// Current orientation.
+        /// </summary>
+        /// <since_tizen> 6 </since_tizen>
+        /// This will be public opened in tizen_5.5 after ACR done. Before ACR, need to be hidden as inhouse API.
+        [EditorBrowsable(EditorBrowsableState.Never)]
+        protected int Orientation { get; set; }
+
+        /// <summary>
         /// Retrieves the first visible item position.
         /// </summary>
         /// <since_tizen> 6 </since_tizen>
@@ -167,7 +167,7 @@ namespace Tizen.NUI.Components
         [EditorBrowsable(EditorBrowsableState.Never)]
         public override bool CanScrollHorizontally()
         {
-            return mOrientation == HORIZONTAL;
+            return Orientation == HORIZONTAL;
         }
 
         /// <summary>
@@ -178,7 +178,7 @@ namespace Tizen.NUI.Components
         [EditorBrowsable(EditorBrowsableState.Never)]
         public override bool CanScrollVertically()
         {
-            return mOrientation == VERTICAL;
+            return Orientation == VERTICAL;
         }
 
         /// <summary>
@@ -249,7 +249,7 @@ namespace Tizen.NUI.Components
         [EditorBrowsable(EditorBrowsableState.Never)]
         public override float ScrollHorizontallyBy(float dx, FlexibleViewRecycler recycler, bool immediate)
         {
-            if (mOrientation == VERTICAL)
+            if (Orientation == VERTICAL)
             {
                 return 0;
             }
@@ -266,7 +266,7 @@ namespace Tizen.NUI.Components
         [EditorBrowsable(EditorBrowsableState.Never)]
         public override float ScrollVerticallyBy(float dy, FlexibleViewRecycler recycler, bool immediate)
         {
-            if (mOrientation == HORIZONTAL)
+            if (Orientation == HORIZONTAL)
             {
                 return 0;
             }
@@ -406,7 +406,7 @@ namespace Tizen.NUI.Components
         [EditorBrowsable(EditorBrowsableState.Never)]
         protected override int GetNextPosition(int position, FlexibleViewLayoutManager.Direction direction)
         {
-            if (mOrientation == HORIZONTAL)
+            if (Orientation == HORIZONTAL)
             {
                 switch (direction)
                 {
index 4d465b0..8a43ce3 100755 (executable)
@@ -28,6 +28,8 @@ namespace Tizen.NUI.Components
     /// Please note that this class will be replaced with Scrollbar class in the near future.
     /// </remarks>
     /// <since_tizen> 6 </since_tizen>
+    /// This will be deprecated
+    [Obsolete("Deprecated in API8; Will be removed in API10")]
     public class ScrollBar : Control
     {
         /// This will be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API.
@@ -138,6 +140,8 @@ namespace Tizen.NUI.Components
         /// The constructor of ScrollBar.
         /// </summary>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public ScrollBar() : base()
         {
             Initialize();
@@ -147,7 +151,7 @@ namespace Tizen.NUI.Components
         /// The constructor of ScrollBar with specific style.
         /// </summary>
         /// <param name="style">style name</param>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         public ScrollBar(string style) : base(style)
         {
             Initialize();
@@ -157,7 +161,7 @@ namespace Tizen.NUI.Components
         /// The constructor of ScrollBar with specific style.
         /// </summary>
         /// <param name="scrollBarStyle">The style object to initialize the ScrollBar.</param>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         public ScrollBar(ScrollBarStyle scrollBarStyle) : base(scrollBarStyle)
         {
             Initialize();
@@ -167,18 +171,24 @@ namespace Tizen.NUI.Components
         /// The direction type of the Scroll.
         /// </summary>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public enum DirectionType
         {
             /// <summary>
             /// The Horizontal type.
             /// </summary>
             /// <since_tizen> 6 </since_tizen>
+            /// This will be deprecated
+            [Obsolete("Deprecated in API8; Will be removed in API10")]
             Horizontal,
 
             /// <summary>
             /// The Vertical type.
             /// </summary>
             /// <since_tizen> 6 </since_tizen>
+            /// This will be deprecated
+            [Obsolete("Deprecated in API8; Will be removed in API10")]
             Vertical
         }
 
@@ -186,13 +196,15 @@ namespace Tizen.NUI.Components
         /// <summary>
         /// Get style of scrollbar.
         /// </summary>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         public new ScrollBarStyle Style => ViewStyle as ScrollBarStyle;
 
         /// <summary>
         /// The property to get/set the direction of the ScrollBar.
         /// </summary>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public DirectionType Direction
         {
             get
@@ -223,6 +235,8 @@ namespace Tizen.NUI.Components
         /// </code>
         /// </example>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public Size ThumbSize
         {
             get
@@ -243,6 +257,8 @@ namespace Tizen.NUI.Components
         /// The property to get/set the image URL of the track object.
         /// </summary>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public string TrackImageURL
         {
             get
@@ -263,6 +279,8 @@ namespace Tizen.NUI.Components
         /// The property to get/set the color of the track object.
         /// </summary>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public Color TrackColor
         {
             get
@@ -283,6 +301,8 @@ namespace Tizen.NUI.Components
         /// The property to get/set the color of the thumb object.
         /// </summary>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public Color ThumbColor
         {
             get
@@ -303,6 +323,8 @@ namespace Tizen.NUI.Components
         /// The property to get/set the max value of the ScrollBar.
         /// </summary>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public int MaxValue
         {
             get
@@ -319,6 +341,8 @@ namespace Tizen.NUI.Components
         /// The property to get/set the min value of the ScrollBar.
         /// </summary>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public int MinValue
         {
             get
@@ -351,6 +375,8 @@ namespace Tizen.NUI.Components
         /// </code>
         /// </example>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public int CurrentValue
         {
             get
@@ -367,6 +393,8 @@ namespace Tizen.NUI.Components
         /// Property to set/get animation duration.
         /// </summary>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public uint Duration
         {
             get
@@ -402,6 +430,8 @@ namespace Tizen.NUI.Components
         /// </code>
         /// </example>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         public void SetCurrentValue(int currentValue, bool enableAnimation = true)
         {
             if (currentValue < minValue || currentValue > maxValue)
@@ -421,6 +451,8 @@ namespace Tizen.NUI.Components
         /// </summary>
         /// <param name="type">The DisposeTypes value.</param>
         /// <since_tizen> 6 </since_tizen>
+        /// This will be deprecated
+        [Obsolete("Deprecated in API8; Will be removed in API10")]
         protected override void Dispose(DisposeTypes type)
         {
             if (disposed)
@@ -459,7 +491,7 @@ namespace Tizen.NUI.Components
         /// Get Scrollbar style.
         /// </summary>
         /// <returns>The default scrollbar style.</returns>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         protected override ViewStyle CreateViewStyle()
         {
             return new ScrollBarStyle();
@@ -470,7 +502,7 @@ namespace Tizen.NUI.Components
         /// </summary>
         /// <param name="sender">The sender</param>
         /// <param name="e">The event data</param>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         protected override void OnThemeChangedEvent(object sender, StyleManager.ThemeChangeEventArgs e)
         {
             ScrollBarStyle tempStyle = StyleManager.Instance.GetViewStyle(StyleName) as ScrollBarStyle;
index bf995b0..65636f9 100644 (file)
@@ -48,7 +48,7 @@ namespace Tizen.NUI.Components
 
                 if (Container != null)
                 {
-                    Layout(mPrevScrollPosition);
+                    Layout(PrevScrollPosition);
                 }
             }
         }
@@ -74,7 +74,7 @@ namespace Tizen.NUI.Components
 
                 if (Container != null)
                 {
-                    Layout(mPrevScrollPosition);
+                    Layout(PrevScrollPosition);
                 }
             }
         }
@@ -111,7 +111,7 @@ namespace Tizen.NUI.Components
         public override float CalculateLayoutOrientationSize()
         {
             float orientationFactor = LayoutOrientation == Orientation.Horizontal ? Rows : Columns;
-            return mStepSize * (int)Math.Ceiling((double)DataCount / (double)orientationFactor);
+            return StepSize * (int)Math.Ceiling((double)DataCount / (double)orientationFactor);
         }
 
 
@@ -173,9 +173,9 @@ namespace Tizen.NUI.Components
                 previousItem = item;
             }
 
-            if (mStepSize == 0)
+            if (StepSize == 0)
             {
-                mStepSize = LayoutOrientation == Orientation.Horizontal ? ItemSize.Width : ItemSize.Height;
+                StepSize = LayoutOrientation == Orientation.Horizontal ? ItemSize.Width : ItemSize.Height;
             }
         }
 
@@ -190,7 +190,7 @@ namespace Tizen.NUI.Components
         public override List<RecycleItem> Recycle(float scrollPosition)
         {
             List<RecycleItem> result = new List<RecycleItem>();
-            bool checkFront = (mPrevScrollPosition - scrollPosition) > 0;
+            bool checkFront = (PrevScrollPosition - scrollPosition) > 0;
 
             int itemInGroup = LayoutOrientation == Orientation.Horizontal ? Rows : Columns;
 
@@ -235,7 +235,7 @@ namespace Tizen.NUI.Components
             }
 
 
-            mPrevScrollPosition = scrollPosition;
+            PrevScrollPosition = scrollPosition;
 
             return result;
         }
index c40da45..c8630a2 100644 (file)
@@ -101,9 +101,9 @@ namespace Tizen.NUI.Components
                 // Tizen.Log.Error("NUI","["+item.DataIndex+"] "+item.Position.Y+" ==== \n");
             }
 
-            if(mStepSize == 0)
+            if(StepSize == 0)
             {
-                mStepSize = LayoutOrientation == Orientation.Horizontal?ItemSize.Width:ItemSize.Height;
+                StepSize = LayoutOrientation == Orientation.Horizontal?ItemSize.Width:ItemSize.Height;
             }
         }
 
@@ -115,7 +115,7 @@ namespace Tizen.NUI.Components
         [EditorBrowsable(EditorBrowsableState.Never)]
         public override float CalculateLayoutOrientationSize()
         {
-            return mStepSize * DataCount;
+            return StepSize * DataCount;
         }
 
         /// <summary>
@@ -129,7 +129,7 @@ namespace Tizen.NUI.Components
         {
             List<RecycleItem> result = new List<RecycleItem>();
           
-            bool checkFront = (mPrevScrollPosition - scrollPosition) > 0;
+            bool checkFront = (PrevScrollPosition - scrollPosition) > 0;
 
             if(checkFront)
             {
@@ -161,7 +161,7 @@ namespace Tizen.NUI.Components
                 }
             }
 
-            mPrevScrollPosition = scrollPosition;
+            PrevScrollPosition = scrollPosition;
 
             return result;
         }
index af4c4db..95e3407 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2020 Samsung Electronics Co., Ltd.
+/* Copyright (c) 2020 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -28,10 +28,6 @@ namespace Tizen.NUI.Components
     [EditorBrowsable(EditorBrowsableState.Never)]
     public class RecycleLayoutManager
     {
-        protected float mPrevScrollPosition = 0.0f;
-        protected int mPrevFirstDataIndex = 0;
-        protected float mStepSize = 0.0f;
-
         /// <summary>
         /// Enumeration for the direction in which the content is laid out
         /// </summary>
@@ -86,12 +82,7 @@ namespace Tizen.NUI.Components
         /// <since_tizen> 8 </since_tizen>
         /// This may be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API
         [EditorBrowsable(EditorBrowsableState.Never)]
-        public float StepSize{
-            get
-            {
-                return mStepSize;
-            }
-        }
+        public float StepSize { get; protected set; }
 
         /// <summary>
         /// How far can you reach the next item.
@@ -102,6 +93,13 @@ namespace Tizen.NUI.Components
         public int DataCount{get; set;}
 
         /// <summary>
+        /// The last scrolled position which is calculated by ScrollableBase. The value should be updated in the Recycle() method.
+        /// </summary>
+        /// This may be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API
+        [EditorBrowsable(EditorBrowsableState.Never)]
+        protected float PrevScrollPosition { get; set; }
+
+        /// <summary>
         /// This is called to find out where items are lain out according to current scroll position.
         /// </summary>
         /// <param name="scrollPosition">Scroll position which is calculated by ScrollableBase</param>
@@ -149,4 +147,4 @@ namespace Tizen.NUI.Components
             return scrollPosition;
         }
     }
-}
\ No newline at end of file
+}
index ac592cd..d5ac23d 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2020 Samsung Electronics Co., Ltd.
+/* Copyright (c) 2020 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -27,10 +27,9 @@ namespace Tizen.NUI.Components
     [EditorBrowsable(EditorBrowsableState.Never)]
     public class RecyclerView : ScrollableBase
     {
-        protected RecycleAdapter mAdapter;
-        protected View mContainer;
-        protected RecycleLayoutManager mLayoutManager;
-        protected int mTotalItemCount = 15;
+        private RecycleAdapter adapter;
+        private RecycleLayoutManager layoutManager;
+        private int totalItemCount = 15;
         private List<PropertyNotification> notifications = new List<PropertyNotification>();
 
         public RecyclerView() : base()
@@ -55,31 +54,31 @@ namespace Tizen.NUI.Components
         {
             Scrolling += OnScrolling;
 
-            mAdapter = adapter;
-            mAdapter.OnDataChanged += OnAdapterDataChanged;
+            this.adapter = adapter;
+            this.adapter.OnDataChanged += OnAdapterDataChanged;
 
-            mLayoutManager = layoutManager;
-            mLayoutManager.Container = ContentContainer;
-            mLayoutManager.ItemSize = mAdapter.CreateRecycleItem().Size;
-            mLayoutManager.DataCount = mAdapter.Data.Count;
+            this.layoutManager = layoutManager;
+            this.layoutManager.Container = ContentContainer;
+            this.layoutManager.ItemSize = this.adapter.CreateRecycleItem().Size;
+            this.layoutManager.DataCount = this.adapter.Data.Count;
 
             InitializeItems();
         }
 
         private void OnItemSizeChanged(object source, PropertyNotification.NotifyEventArgs args)
         {
-            mLayoutManager.Layout(ScrollingDirection == Direction.Horizontal ? ContentContainer.CurrentPosition.X : ContentContainer.CurrentPosition.Y);
+            layoutManager.Layout(ScrollingDirection == Direction.Horizontal ? ContentContainer.CurrentPosition.X : ContentContainer.CurrentPosition.Y);
         }
         
         public int TotalItemCount 
         {
             get
             {
-                return mTotalItemCount;
+                return totalItemCount;
             }
             set
             {
-                mTotalItemCount = value;
+                totalItemCount = value;
                 InitializeItems();
             }
         }
@@ -93,15 +92,15 @@ namespace Tizen.NUI.Components
                 notifications.RemoveAt(i);
             }
 
-            for (int i = 0; i < mTotalItemCount; i++)
+            for (int i = 0; i < totalItemCount; i++)
             {
-                RecycleItem item = mAdapter.CreateRecycleItem();
+                RecycleItem item = adapter.CreateRecycleItem();
                 item.DataIndex = i;
                 item.Name = "[" + i + "] recycle";
 
-                if (i < mAdapter.Data.Count)
+                if (i < adapter.Data.Count)
                 {
-                    mAdapter.BindData(item);
+                    adapter.BindData(item);
                 }
                 Add(item);
 
@@ -110,15 +109,15 @@ namespace Tizen.NUI.Components
                 notifications.Add(noti);
             }
 
-            mLayoutManager.Layout(0.0f);
+            layoutManager.Layout(0.0f);
 
             if (ScrollingDirection == Direction.Horizontal)
             {
-                ContentContainer.SizeWidth = mLayoutManager.CalculateLayoutOrientationSize();
+                ContentContainer.SizeWidth = layoutManager.CalculateLayoutOrientationSize();
             }
             else
             {
-                ContentContainer.SizeHeight = mLayoutManager.CalculateLayoutOrientationSize();
+                ContentContainer.SizeHeight = layoutManager.CalculateLayoutOrientationSize();
             }
         }
 
@@ -135,11 +134,11 @@ namespace Tizen.NUI.Components
 
                 if (ScrollingDirection == Direction.Horizontal)
                 {
-                    ContentContainer.SizeWidth = mLayoutManager.CalculateLayoutOrientationSize();
+                    ContentContainer.SizeWidth = layoutManager.CalculateLayoutOrientationSize();
                 }
                 else
                 {
-                    ContentContainer.SizeHeight = mLayoutManager.CalculateLayoutOrientationSize();
+                    ContentContainer.SizeHeight = layoutManager.CalculateLayoutOrientationSize();
                 }
             }
         }
@@ -154,19 +153,19 @@ namespace Tizen.NUI.Components
         {
             get
             {
-                return mAdapter;
+                return adapter;
             }
             set
             {
-                if(mAdapter != null)
+                if (adapter != null)
                 {
-                    mAdapter.OnDataChanged -= OnAdapterDataChanged;
+                    adapter.OnDataChanged -= OnAdapterDataChanged;
                 }
 
-                mAdapter = value;
-                mAdapter.OnDataChanged += OnAdapterDataChanged;
-                mLayoutManager.ItemSize = mAdapter.CreateRecycleItem().Size;
-                mLayoutManager.DataCount = mAdapter.Data.Count;
+                adapter = value;
+                adapter.OnDataChanged += OnAdapterDataChanged;
+                layoutManager.ItemSize = adapter.CreateRecycleItem().Size;
+                layoutManager.DataCount = adapter.Data.Count;
                 InitializeItems();
             }
         }
@@ -181,22 +180,22 @@ namespace Tizen.NUI.Components
         {
             get
             {
-                return mLayoutManager;
+                return layoutManager;
             }
-            set
+            protected set
             {
-                mLayoutManager = value;
-                mLayoutManager.Container = ContentContainer;
-                mLayoutManager.ItemSize = mAdapter.CreateRecycleItem().Size;
-                mLayoutManager.DataCount = mAdapter.Data.Count;
+                LayoutManager = value;
+                LayoutManager.Container = ContentContainer;
+                LayoutManager.ItemSize = Adapter.CreateRecycleItem().Size;
+                LayoutManager.DataCount = Adapter.Data.Count;
                 InitializeItems();
             }
         }
 
         private void OnScrolling(object source, ScrollEventArgs args)
         {
-            mLayoutManager.Layout(ScrollingDirection == Direction.Horizontal ? args.Position.X : args.Position.Y);
-            List<RecycleItem> recycledItemList = mLayoutManager.Recycle(ScrollingDirection == Direction.Horizontal ? args.Position.X : args.Position.Y);
+            layoutManager.Layout(ScrollingDirection == Direction.Horizontal ? args.Position.X : args.Position.Y);
+            List<RecycleItem> recycledItemList = layoutManager.Recycle(ScrollingDirection == Direction.Horizontal ? args.Position.X : args.Position.Y);
             BindData(recycledItemList);
         }
 
@@ -216,11 +215,11 @@ namespace Tizen.NUI.Components
         {
             foreach (RecycleItem item in changedData)
             {
-                if (item.DataIndex > -1 && item.DataIndex < mAdapter.Data.Count)
+                if (item.DataIndex > -1 && item.DataIndex < adapter.Data.Count)
                 {
                     item.Show();
                     item.Name = "["+item.DataIndex+"]";
-                    mAdapter.BindData(item);
+                    adapter.BindData(item);
                 }
                 else
                 {
@@ -242,7 +241,7 @@ namespace Tizen.NUI.Components
         {
             // Destination is depending on implementation of layout manager.
             // Get destination from layout manager.
-            return mLayoutManager.CalculateCandidateScrollPosition(position);
+            return layoutManager.CalculateCandidateScrollPosition(position);
         }
     }
 }
index 234ce25..0833c32 100755 (executable)
@@ -26,7 +26,7 @@ namespace Tizen.NUI.Components
     /// <remarks>
     /// Please note that this class will be replaced with ScrollbarStyle class in the near future.
     /// </remarks>
-    /// <since_tizen> 8 </since_tizen>
+    [EditorBrowsable(EditorBrowsableState.Never)]
     public class ScrollBarStyle : ControlStyle
     {
         static ScrollBarStyle() { }
@@ -34,7 +34,7 @@ namespace Tizen.NUI.Components
         /// <summary>
         /// Creates a new instance of a ScrollBarStyle.
         /// </summary>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         public ScrollBarStyle() : base()
         {
             InitSubStyle();
@@ -45,7 +45,7 @@ namespace Tizen.NUI.Components
         /// Creates a new instance of a ScrollBarStyle with style.
         /// </summary>
         /// <param name="style">Create ScrollBarStyle by style customized by user.</param>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         public ScrollBarStyle(ScrollBarStyle style) : base(style)
         {
             if (null == style) return;
@@ -58,32 +58,32 @@ namespace Tizen.NUI.Components
         /// <summary>
         /// Get or set track image style.
         /// </summary>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         public ImageViewStyle Track { get; set; }
 
         /// <summary>
         /// Get or set thumb image style.
         /// </summary>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         public ImageViewStyle Thumb { get; set; }
 
         /// <summary>
         /// Get or set direction type.
         /// </summary>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         public ScrollBar.DirectionType? Direction { get; set; }
 
         /// <summary>
         /// Get or set duration.
         /// </summary>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         public uint Duration { get; set; }
 
         /// <summary>
         /// Style's clone function.
         /// </summary>
         /// <param name="bindableObject">The style that need to copy.</param>
-        /// <since_tizen> 8 </since_tizen>
+        [EditorBrowsable(EditorBrowsableState.Never)]
         public override void CopyFrom(BindableObject bindableObject)
         {
             base.CopyFrom(bindableObject);
index bb20c92..3d472ae 100644 (file)
@@ -69,7 +69,7 @@ namespace Tizen.NUI.Wearable
 
         public override float CalculateLayoutOrientationSize()
         {
-            return mStepSize * (DataCount-1);
+            return StepSize * (DataCount-1);
         }
 
         public override void Layout(float scrollPosition)
@@ -77,21 +77,21 @@ namespace Tizen.NUI.Wearable
             RecycleItem centerItem = Container.Children[FocusedIndex] as RecycleItem;
             float centerItemPosition = LayoutOrientation == Orientation.Horizontal ? centerItem.Position.X : centerItem.Position.Y;
 
-            Vector2 stepRange = new Vector2(-scrollPosition - mStepSize + 1.0f, -scrollPosition + mStepSize - 1.0f);
+            Vector2 stepRange = new Vector2(-scrollPosition - StepSize + 1.0f, -scrollPosition + StepSize - 1.0f);
             Vector2 visibleRange = new Vector2(Math.Abs(scrollPosition) - 180, Math.Abs(scrollPosition) + 180);
 
-            if (mStepSize != 0 && centerItemPosition <= stepRange.X)
+            if (StepSize != 0 && centerItemPosition <= stepRange.X)
             {
                 FocusedIndex = Math.Min(Container.Children.Count - 1, FocusedIndex + 1);
                 centerItem = Container.Children[FocusedIndex] as RecycleItem;
-                centerItem.Position = new Position(0.0f, Math.Abs(mStepSize * (centerItem.DataIndex)));
+                centerItem.Position = new Position(0.0f, Math.Abs(StepSize * (centerItem.DataIndex)));
                 centerItem.Scale = new Vector3(1.0f, 1.0f, 1.0f);
             }
-            else if (mStepSize != 0 && centerItemPosition >= stepRange.Y)
+            else if (StepSize != 0 && centerItemPosition >= stepRange.Y)
             {
                 FocusedIndex = Math.Max(0, FocusedIndex - 1);
                 centerItem = Container.Children[FocusedIndex] as RecycleItem;
-                centerItem.Position = new Position(0.0f, Math.Abs(mStepSize * (centerItem.DataIndex)));
+                centerItem.Position = new Position(0.0f, Math.Abs(StepSize * (centerItem.DataIndex)));
                 centerItem.Scale = new Vector3(1.0f, 1.0f, 1.0f);
             }
             else
@@ -168,18 +168,18 @@ namespace Tizen.NUI.Wearable
                 }
             }
 
-            if (mStepSize == 0)
+            if (StepSize == 0)
             {
                 if (LayoutOrientation == Orientation.Horizontal)
                 {
-                    mStepSize = Container.Children[0].Size.Width / 2.0f + Container.Children[1].Size.Width * Container.Children[1].Scale.X / 2.0f;
+                    StepSize = Container.Children[0].Size.Width / 2.0f + Container.Children[1].Size.Width * Container.Children[1].Scale.X / 2.0f;
                 }
                 else
                 {
-                    mStepSize = Container.Children[0].Size.Height / 2.0f + Container.Children[1].Size.Height * Container.Children[1].Scale.X / 2.0f;
+                    StepSize = Container.Children[0].Size.Height / 2.0f + Container.Children[1].Size.Height * Container.Children[1].Scale.X / 2.0f;
                 }
 
-                mStepSize = float.IsNaN(mStepSize)?0:mStepSize;
+                StepSize = float.IsNaN(StepSize)?0:StepSize;
             }
         }
 
@@ -187,7 +187,7 @@ namespace Tizen.NUI.Wearable
         {
             List<RecycleItem> result = new List<RecycleItem>();
 
-            bool isBack = scrollPosition - mPrevScrollPosition < 0;
+            bool isBack = scrollPosition - PrevScrollPosition < 0;
 
             int previousFocusIndex = FocusedIndex;
 
@@ -220,7 +220,7 @@ namespace Tizen.NUI.Wearable
                 FocusedIndex--;
             }
 
-            mPrevScrollPosition = scrollPosition;
+            PrevScrollPosition = scrollPosition;
 
             return result;
         }
@@ -249,13 +249,13 @@ namespace Tizen.NUI.Wearable
 
         public override float CalculateCandidateScrollPosition(float scrollPosition)
         {
-            int value = (int)(Math.Abs(scrollPosition) / mStepSize);
-            float remain = Math.Abs(scrollPosition) % mStepSize;
+            int value = (int)(Math.Abs(scrollPosition) / StepSize);
+            float remain = Math.Abs(scrollPosition) % StepSize;
 
-            int newValue = remain > mStepSize / 2.0f ? value + 1 : value;
+            int newValue = remain > StepSize / 2.0f ? value + 1 : value;
 
             CurrentFocusedIndex = newValue;
-            return -newValue * mStepSize;
+            return -newValue * StepSize;
         }
     }
 }
\ No newline at end of file
index e9d07ee..2380611 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2020 Samsung Electronics Co., Ltd.
+/* Copyright (c) 2020 Samsung Electronics Co., Ltd.
  *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
@@ -105,7 +105,7 @@ namespace Tizen.NUI.Wearable
                     FocusedItem = item;
                     FocusedItem.OnFocusGained();
 
-                    ScrollTo(item.DataIndex * mLayoutManager.StepSize, animated);
+                    ScrollTo(item.DataIndex * LayoutManager.StepSize, animated);
                 }
             }
         }
@@ -122,7 +122,7 @@ namespace Tizen.NUI.Wearable
         /// This may be public opened in tizen_6.0 after ACR done. Before ACR, need to be hidden as inhouse API
         protected override void OnPreReachedTargetPosition(float targetPosition)
         {
-            int targetDataIndex = (int)Math.Round(Math.Abs(targetPosition) / mLayoutManager.StepSize);
+            int targetDataIndex = (int)Math.Round(Math.Abs(targetPosition) / LayoutManager.StepSize);
 
             for (int i = 0; i < Children.Count; i++)
             {