[NUI] Gallery App button position issue (#400)
authordongsug-song <35130733+dongsug-song@users.noreply.github.com>
Sat, 18 Aug 2018 10:31:30 +0000 (19:31 +0900)
committerGitHub <noreply@github.com>
Sat, 18 Aug 2018 10:31:30 +0000 (19:31 +0900)
src/Tizen.NUI/src/public/BaseComponents/View.cs

index 448de5f..be55ce4 100755 (executable)
@@ -1221,8 +1221,6 @@ namespace Tizen.NUI.BaseComponents
 
         private global::System.Runtime.InteropServices.HandleRef swigCPtr;
 
-        private bool layoutSet = false; // Flag to indicate if SetLayout was called or View was automatically given a Layout
-
         internal View(global::System.IntPtr cPtr, bool cMemoryOwn) : base(NDalicPINVOKE.View_SWIGUpcast(cPtr), cMemoryOwn)
         {
             swigCPtr = new global::System.Runtime.InteropServices.HandleRef(this, cPtr);
@@ -1283,7 +1281,7 @@ namespace Tizen.NUI.BaseComponents
                     oldParent.Remove(child);
                 }
 
-                if (layoutSet = true && child.Layout == null) // Only give children a layout if parent an explict container
+                if (child.Layout == null)
                 {
                     LayoutItem layoutItem = new LayoutItem();
                     child.Layout = layoutItem;
@@ -3182,11 +3180,8 @@ namespace Tizen.NUI.BaseComponents
             set
             {
                 SetValue(Size2DProperty, value);
-                if ( this.Layout != null)
-                {
                   SetProperty(LayoutItemWrapper.ChildProperty.WIDTH_SPECIFICATION, new Tizen.NUI.PropertyValue(value.Width));
                   SetProperty(LayoutItemWrapper.ChildProperty.HEIGHT_SPECIFICATION, new Tizen.NUI.PropertyValue(value.Height));
-                }
                 NotifyPropertyChanged();
             }
         }
@@ -3448,7 +3443,6 @@ namespace Tizen.NUI.BaseComponents
             {
                 Tizen.NUI.NDalicManualPINVOKE.SetLayout__SWIG_1(View.getCPtr(this), LayoutItem.getCPtr(value));
                 value.LayoutChildren.Clear();
-                layoutSet = true;
                 foreach (View view in Children)
                 {
                     value.LayoutChildren.Add(view.Layout);