[NUI] Add more log info for recursive dependency in LinearLayout
authorJaehyun Cho <jae_hyun.cho@samsung.com>
Tue, 25 May 2021 11:16:00 +0000 (20:16 +0900)
committerdongsug-song <35130733+dongsug-song@users.noreply.github.com>
Wed, 26 May 2021 01:00:09 +0000 (10:00 +0900)
If recursive dependency exists between LinearLayout and its child
layout, then error log is printed.

To give more log info for recursive dependency in LinearLayout, parent
and child Owner info are added.

src/Tizen.NUI/src/public/Layouting/LinearLayout.cs

index 2b45c94..f986536 100755 (executable)
@@ -358,11 +358,11 @@ namespace Tizen.NUI
                     {
                         if (childDesiredHeight == LayoutParamPolicies.MatchParent)
                         {
-                            Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's HeightSpecification is WrapContent and child layout's HeightSpecification is MatchParent!");
+                            Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s HeightSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s HeightSpecification is MatchParent!");
                         }
                         else
                         {
-                            Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's HeightSpecification is WrapContent and child layout's HeightSpecification is 0 with positive weight!");
+                            Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s HeightSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s HeightSpecification is 0 with positive weight!");
                         }
                     }
                 }
@@ -382,11 +382,11 @@ namespace Tizen.NUI
                         {
                             if (childDesiredWidth == LayoutParamPolicies.MatchParent)
                             {
-                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's WidthSpecification is WrapContent and child layout's WidthSpecification is MatchParent!");
+                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s WidthSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s WidthSpecification is MatchParent!");
                             }
                             else
                             {
-                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's WidthSpecification is WrapContent and child layout's WidthSpecification is 0 with positive weight!");
+                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s WidthSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s WidthSpecification is 0 with positive weight!");
                             }
                         }
                     }
@@ -436,11 +436,11 @@ namespace Tizen.NUI
                         {
                             if (childDesiredWidth == LayoutParamPolicies.MatchParent)
                             {
-                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's WidthSpecification is WrapContent and child layout's WidthSpecification is MatchParent!");
+                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s WidthSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s WidthSpecification is MatchParent!");
                             }
                             else
                             {
-                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's WidthSpecification is WrapContent and child layout's WidthSpecification is 0 with positive weight!");
+                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s WidthSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s WidthSpecification is 0 with positive weight!");
                             }
                         }
                     }
@@ -576,11 +576,11 @@ namespace Tizen.NUI
                     {
                         if (childDesiredWidth == LayoutParamPolicies.MatchParent)
                         {
-                            Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's WidthSpecification is WrapContent and child layout's WidthSpecification is MatchParent!");
+                            Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s WidthSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s WidthSpecification is MatchParent!");
                         }
                         else
                         {
-                            Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's WidthSpecification is WrapContent and child layout's WidthSpecification is 0 with positive weight!");
+                            Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s WidthSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s WidthSpecification is 0 with positive weight!");
                         }
                     }
                 }
@@ -600,11 +600,11 @@ namespace Tizen.NUI
                         {
                             if (childDesiredHeight == LayoutParamPolicies.MatchParent)
                             {
-                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's HeightSpecification is WrapContent and child layout's HeightSpecification is MatchParent!");
+                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s HeightSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s HeightSpecification is MatchParent!");
                             }
                             else
                             {
-                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's HeightSpecification is WrapContent and child layout's HeightSpecification is 0 with positive weight!");
+                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s HeightSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s HeightSpecification is 0 with positive weight!");
                             }
                         }
                     }
@@ -654,11 +654,11 @@ namespace Tizen.NUI
                         {
                             if (childDesiredHeight == LayoutParamPolicies.MatchParent)
                             {
-                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's HeightSpecification is WrapContent and child layout's HeightSpecification is MatchParent!");
+                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s HeightSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s HeightSpecification is MatchParent!");
                             }
                             else
                             {
-                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout's HeightSpecification is WrapContent and child layout's HeightSpecification is 0 with positive weight!");
+                                Tizen.Log.Error("NUI", "There is a recursive reference! Parent layout(Owner: " + Owner + ")'s HeightSpecification is WrapContent and child layout(Owner: " + childLayout.Owner + ")'s HeightSpecification is 0 with positive weight!");
                             }
                         }
                     }