From fdeb18a80ab8ca5c24eb22920edff1efcd96b332 Mon Sep 17 00:00:00 2001 From: Jaehyun Cho Date: Wed, 14 Jul 2021 22:49:04 +0900 Subject: [PATCH] [NUI] Fix AppBar Content's Layout properties Since LinearLayout's size calculation logic has been fixed, AppBar Content's Layout properties are fixed to calculate size correctly. After fixing LinearLayout's size calculation logic, Weight is valid only if Width/HeightSpecification is MatchParent. AppBarStyle's ActionView and ActionButton's default size is fixed to show its own size. --- src/Tizen.NUI.Components/Controls/Navigation/AppBar.cs | 5 +++-- src/Tizen.NUI.Components/Theme/DefaultThemeCommon.cs | 6 +++--- 2 files changed, 6 insertions(+), 5 deletions(-) diff --git a/src/Tizen.NUI.Components/Controls/Navigation/AppBar.cs b/src/Tizen.NUI.Components/Controls/Navigation/AppBar.cs index 3bb879d..3439a90 100755 --- a/src/Tizen.NUI.Components/Controls/Navigation/AppBar.cs +++ b/src/Tizen.NUI.Components/Controls/Navigation/AppBar.cs @@ -609,7 +609,6 @@ namespace Tizen.NUI.Components return new TextLabel() { HeightSpecification = LayoutParamPolicies.MatchParent, - Weight = 1.0f, }; } @@ -620,8 +619,10 @@ namespace Tizen.NUI.Components Layout = new LinearLayout() { LinearOrientation = LinearLayout.Orientation.Horizontal, + LinearAlignment = LinearLayout.Alignment.End, }, - Weight = 0.0f, + WidthSpecification = LayoutParamPolicies.MatchParent, + HeightSpecification = LayoutParamPolicies.MatchParent, }; } diff --git a/src/Tizen.NUI.Components/Theme/DefaultThemeCommon.cs b/src/Tizen.NUI.Components/Theme/DefaultThemeCommon.cs index 9db1ac2..9f0ec4c 100755 --- a/src/Tizen.NUI.Components/Theme/DefaultThemeCommon.cs +++ b/src/Tizen.NUI.Components/Theme/DefaultThemeCommon.cs @@ -449,13 +449,13 @@ namespace Tizen.NUI.Components }, ActionView = new ViewStyle() { - Size = new Size(-1, 120), + Size = new Size(48, 120), CornerRadius = 0, BackgroundColor = new Color(0, 0, 0, 0), }, ActionButton = new ButtonStyle() { - Size = new Size(-1, 120), + Size = new Size(-2, 120), CornerRadius = 0, BackgroundColor = new Color(0, 0, 0, 0), Text = new TextLabelStyle() @@ -471,7 +471,7 @@ namespace Tizen.NUI.Components }, Icon = new ImageViewStyle() { - Size = new Size(-1, 48), + Size = new Size(48, 48), Color = new Selector() { Normal = new Color("#0A0E4A"), -- 2.7.4