Fix Album window border wrong icons wrong size and stroke width. 73/310173/2 accepted/tizen_9.0_unified accepted/tizen_unified_dev accepted/tizen_unified_toolchain tizen_9.0 accepted/tizen/9.0/unified/20241030.231115 accepted/tizen/unified/20240621.010446 accepted/tizen/unified/dev/20240701.073134 accepted/tizen/unified/toolchain/20240624.121531 accepted/tizen/unified/x/20240624.031954 accepted/tizen/unified/x/asan/20240625.092619 tizen_9.0_m2_release
authorAzijur Rahman Sheatu <azijur.r@samsung.com>
Mon, 27 May 2024 12:13:33 +0000 (18:13 +0600)
committerAzijur Rahman Sheatu <azijur.r@samsung.com>
Mon, 27 May 2024 12:13:33 +0000 (18:13 +0600)
[Issue] TNINE-398

[Problem] Album window border wrong icons wrong size and stroke width are not aligned with GUI guide
[Cause & Measure]
 Cause : Border properties and icons were not set properly.
 Measure : Border properties and new icons are added properly.

Change-Id: Ife4f342ea9bd3c043924b1951651f11e76f435ac
Signed-off-by: azijur-r <azijur.r@samsung.com>
SettingWallpaper/SettingWallpaper/CustomBorder.cs
SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/close.png
SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/leftCorner.png
SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/maximalize.png
SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/minimalize.png
SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/rightCorner.png
SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/smallwindow.png
packaging/org.tizen.cssetting-wallpaper-1.0.0.rpk

index 5a5ca5fb33b70d389845fb6c547bc951a2e93249..2e74528c8787895d485fa7b2118a4b9868d18c78 100644 (file)
@@ -43,10 +43,14 @@ namespace SettingWallpaper
         private ImageView closeIcon;
         private ImageView leftCornerIcon;
 
+        private static Size2D IconSize = new Size2D(48, 48);
+        private const int BorderThickness = 6;
+        private const int BottomViewHeight = 48;
+        private const int BorderCornerRadius = 24;
+
         public event Action CloseClicked;
         public CustomBorder() : base()
         {
-            BorderLineThickness = 0;
             ResizePolicy = Window.BorderResizePolicyType.Free;
             MinSize = new Size2D(320, 280).SpToPx();
         }
@@ -63,28 +67,34 @@ namespace SettingWallpaper
                 return false;
             }
             this.bottomView = bottomView;
+
             bottomView.Layout = new RelativeLayout();
+            bottomView.HeightSpecification = BottomViewHeight.SpToPx();
 
             minimalizeIcon = new ImageView()
             {
+                Size2D = IconSize.SpToPx(),
                 ResourceUrl = MinimalizeIcon,
                 AccessibilityHighlightable = true,
             };
 
             maximalizeIcon = new ImageView()
             {
+                Size2D = IconSize.SpToPx(),
                 ResourceUrl = MaximalizeIcon,
                 AccessibilityHighlightable = true,
             };
 
             closeIcon = new ImageView()
             {
+                Size2D = IconSize.SpToPx(),
                 ResourceUrl = CloseIcon,
                 AccessibilityHighlightable = true,
             };
 
             leftCornerIcon = new ImageView()
             {
+                Size2D = IconSize.SpToPx(),
                 ResourceUrl = LeftCornerIcon,
                 AccessibilityHighlightable = true,
             };
@@ -149,15 +159,15 @@ namespace SettingWallpaper
         public override void CreateBorderView(View borderView)
         {
             this.borderView = borderView;
-            borderView.CornerRadius = new Vector4(0.03f, 0.03f, 0.03f, 0.03f);
-            borderView.CornerRadiusPolicy = VisualTransformPolicyType.Relative;
+
+            BorderLineThickness = (uint)BorderThickness.SpToPx();
             borderView.BackgroundColor = borderBackgroundColor;
         }
 
         public override void OnCreated(View borderView)
         {
             base.OnCreated(borderView);
-            UpdateIcons();
+            UpdateView();
         }
 
         public override bool OnCloseIconTouched(object sender, View.TouchEventArgs e)
@@ -182,29 +192,28 @@ namespace SettingWallpaper
         {
             if (borderView != null)
             {
-                borderView.BackgroundColor = borderBackgroundColor;
                 base.OnResized(width, height);
-                UpdateIcons();
+
+                borderView.BackgroundColor = borderBackgroundColor;
+                UpdateView();
             }
         }
 
-        private void UpdateIcons()
+        private void UpdateView()
         {
-            if (BorderWindow != null && borderView != null)
+            if (BorderWindow != null && borderView != null && maximalizeIcon != null)
             {
+                // CornerRadious needed to be set in the OnResized to get effect properly
+                borderView.CornerRadiusPolicy = VisualTransformPolicyType.Absolute;
+                borderView.CornerRadius = BorderCornerRadius.SpToPx();
+
                 if (BorderWindow.IsMaximized() == true)
                 {
-                    if (maximalizeIcon != null)
-                    {
-                        maximalizeIcon.ResourceUrl = RestoreIcon;
-                    }
+                    maximalizeIcon.ResourceUrl = RestoreIcon;
                 }
                 else
                 {
-                    if (maximalizeIcon != null)
-                    {
-                        maximalizeIcon.ResourceUrl = MaximalizeIcon;
-                    }
+                    maximalizeIcon.ResourceUrl = MaximalizeIcon;
                 }
             }
         }
index c49e4801e26ec86939f0c9e15df4e6364af7b77c..6b095540f84590d25f9c86d26c09b38d0e428d2d 100644 (file)
Binary files a/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/close.png and b/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/close.png differ
index 6f82440282f03d8f8e5362a32ab8f0c778fcc393..72e2119efa7f66e6df7f557e8154bb846716642e 100644 (file)
Binary files a/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/leftCorner.png and b/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/leftCorner.png differ
index c5cbbaf0009a8fcbd914fb673c04c9cb79f60c32..320b60241f2273eb3cb17988fe9dff0c06690ea1 100644 (file)
Binary files a/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/maximalize.png and b/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/maximalize.png differ
index 6b116b2cfdb560593bb8b9eeb710e5f6e2ea0661..266d54898aae64782816c5ca18fa9159dd5e7d0b 100644 (file)
Binary files a/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/minimalize.png and b/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/minimalize.png differ
index 68d837f44bf20b6bc52aba7ab9f502794bc3de3d..05871f31480527e1a6f3539402fefdace42ba9c6 100644 (file)
Binary files a/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/rightCorner.png and b/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/rightCorner.png differ
index 8f4263be400e606541faca8b3e14b9bffd548a44..9def8da11bd276208214deb8b119ea0821c681e9 100644 (file)
Binary files a/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/smallwindow.png and b/SettingWallpaper/SettingWallpaper/res/allowed/SettingWallpaper/images/smallwindow.png differ
index 4eb15d7b0b87f6f14ba536295198450f828e0e79..34861a595ccd7579b49b192356fd9bf147c1b9ba 100644 (file)
Binary files a/packaging/org.tizen.cssetting-wallpaper-1.0.0.rpk and b/packaging/org.tizen.cssetting-wallpaper-1.0.0.rpk differ