[NUI] CanvasView: Add constructor that can be created without viewbox
authorJunsuChoi <jsuya.choi@samsung.com>
Thu, 29 Jul 2021 08:13:46 +0000 (17:13 +0900)
committerdongsug-song <35130733+dongsug-song@users.noreply.github.com>
Tue, 3 Aug 2021 01:50:50 +0000 (10:50 +0900)
Add a constructor so that it can be created without viewBox argument.

src/Tizen.NUI/src/internal/Interop/Interop.CanvasView.cs
src/Tizen.NUI/src/public/BaseComponents/VectorGraphics/CanvasView.cs

index 7c173a9..70d231c 100755 (executable)
@@ -24,6 +24,9 @@ namespace Tizen.NUI
             [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_CanvasView_New__SWIG_0")]
             public static extern global::System.IntPtr New(global::System.Runtime.InteropServices.HandleRef jarg1);
 
+            [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_CanvasView_New__SWIG_1")]
+            public static extern global::System.IntPtr New();
+
             [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_delete_CanvasView")]
             public static extern void DeleteCanvasView(global::System.Runtime.InteropServices.HandleRef jarg1);
 
index e1ea271..7130d11 100755 (executable)
@@ -34,6 +34,15 @@ namespace Tizen.NUI.BaseComponents.VectorGraphics
         /// <summary>
         /// Creates an initialized CanvasView.
         /// </summary>
+        [EditorBrowsable(EditorBrowsableState.Never)]
+        public CanvasView() : this(Interop.CanvasView.New(), true)
+        {
+            if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+        }
+
+        /// <summary>
+        /// Creates an initialized CanvasView.
+        /// </summary>
         /// <param name="viewBox">The size of viewbox.</param>
         /// <exception cref="ArgumentNullException"> Thrown when viewBox is null. </exception>
         /// <since_tizen> 9 </since_tizen>