terms/wifi: add scrollbars 42/236742/1
authorLukasz Stanislawski <lukasz.stanislawski@gmail.com>
Sun, 21 Jun 2020 21:33:13 +0000 (23:33 +0200)
committerLukasz Stanislawski <lukasz.stanislawski@gmail.com>
Sun, 21 Jun 2020 21:33:13 +0000 (23:33 +0200)
Change-Id: I8151e35f0f290d254ea64253c5a9a7e1d7207bdb

Oobe/Oobe.Common/Styles/ScrollbarStyles.cs [new file with mode: 0644]
Oobe/Oobe.Terms/Views/TermsView.cs
Oobe/Oobe.Wifi/Controls/ListView.cs

diff --git a/Oobe/Oobe.Common/Styles/ScrollbarStyles.cs b/Oobe/Oobe.Common/Styles/ScrollbarStyles.cs
new file mode 100644 (file)
index 0000000..0e7c536
--- /dev/null
@@ -0,0 +1,29 @@
+/*
+ * 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.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+using Tizen.NUI;
+using Tizen.NUI.Components;
+
+namespace Oobe.Common.Styles
+{
+    public static class ScrollbarStyles
+    {
+        public static ScrollbarStyle Default = new ScrollbarStyle{
+            ThumbColor = new Color(10.0f/255.0f, 13.0f/255.0f, 73.0f/255.0f, 0.5f),
+            TrackColor = new Color(0.0f, 0.0f, 0.0f, 0.0f),
+        };
+    }
+}
index 0fd994616c15ecc5b50f0521d6bb31c0e8b8c930..2c51e9a881e795342ca315555ef4071f06dc0e04 100644 (file)
@@ -59,13 +59,17 @@ namespace Oobe.Terms.Views
             bounding.Position2D = new Position2D(56 - 6, 112 - 6);
             bounding.Size2D = new Size2D(1086, 331);
 
-            ScrollableBase scroller = new ScrollableBase();
-            scroller.Position2D = new Position2D(120, 136);
-            scroller.Size2D = new Size2D(944, 268);
+            ScrollableBase scroller = new ScrollableBase{
+                Position2D = new Position2D(56, 136),
+                Size2D = new Size2D(1072, 264),
+                Scrollbar = new Scrollbar(ScrollbarStyles.Default),
+                HideScrollBar = false,
+            };
 
             // workaround crash issue in ScrollableBase
             var scrollerContent = new View
             {
+                Padding = new Extents(64, 67, 0, 0),
                 WidthResizePolicy = ResizePolicyType.FillToParent,
                 HeightResizePolicy = ResizePolicyType.FitToChildren,
                 Layout = new LinearLayout(),
index 6885c4cc3288eb6b62084605e21035bf5a3918ba..f07f72d05b72920831390e9663a0e65f31b7f182 100644 (file)
@@ -23,6 +23,7 @@ using System.Threading.Tasks;
 using Tizen.NUI;
 using Tizen.NUI.BaseComponents;
 using Tizen.NUI.Components;
+using Oobe.Common.Styles;
 
 namespace Oobe.Wifi.Controls
 {
@@ -72,6 +73,8 @@ namespace Oobe.Wifi.Controls
                     {
                         Size = new Size(width, height),
                         ScrollingDirection = ScrollableBase.Direction.Vertical,
+                        Scrollbar = new Scrollbar(ScrollbarStyles.Default),
+                        HideScrollBar = false,
                     };
                 }
                 return scrollableBase;