[NUI] Add internal api to create Texture using TbmSurface (#1941)
[platform/core/csapi/tizenfx.git] / src / Tizen.NUI / src / public / Texture.cs
index c35a1f3..68873f7 100755 (executable)
@@ -14,6 +14,7 @@
  * limitations under the License.
  *
  */
+using System;
 using System.ComponentModel;
 
 namespace Tizen.NUI
@@ -46,6 +47,11 @@ namespace Tizen.NUI
 
         }
 
+        internal Texture(IntPtr tbmSurface) : this(Interop.Texture.Texture_New__TbmSurface(tbmSurface), true)
+        {
+            if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+        }
+
         internal Texture(global::System.IntPtr cPtr, bool cMemoryOwn) : base(Interop.Texture.Texture_SWIGUpcast(cPtr), cMemoryOwn)
         {
         }