From 82adc925c607386614c51ed2f1c5e02b4e76bc96 Mon Sep 17 00:00:00 2001 From: Umar Date: Wed, 12 Jul 2017 13:23:08 +0100 Subject: [PATCH] [Tizen] Ensuring that Registry.Unregister is called from the most derived class before the native handle is deleted. Change-Id: Iae8e8445d5b2d351212b5d1572130e636dc4a354 --- src/Tizen.NUI/src/internal/AccessibilityManager.cs | 4 ++++ src/Tizen.NUI/src/internal/Alignment.cs | 4 ++++ src/Tizen.NUI/src/internal/Application.cs | 4 ++++ src/Tizen.NUI/src/internal/AsyncImageLoader.cs | 4 ++++ src/Tizen.NUI/src/internal/BufferImage.cs | 4 ++++ src/Tizen.NUI/src/internal/Builder.cs | 5 ++++- src/Tizen.NUI/src/internal/Camera.cs | 4 ++++ src/Tizen.NUI/src/internal/CustomActor.cs | 4 ++++ src/Tizen.NUI/src/internal/DragAndDropDetector.cs | 4 ++++ src/Tizen.NUI/src/internal/EncodedBufferImage.cs | 4 ++++ src/Tizen.NUI/src/internal/FrameBuffer.cs | 4 ++++ src/Tizen.NUI/src/internal/FrameBufferImage.cs | 4 ++++ src/Tizen.NUI/src/internal/GaussianBlurView.cs | 4 ++++ src/Tizen.NUI/src/internal/GestureDetector.cs | 4 ++++ src/Tizen.NUI/src/internal/Image.cs | 4 ++++ src/Tizen.NUI/src/internal/KeyInputFocusManager.cs | 4 ++++ src/Tizen.NUI/src/internal/LinearConstrainer.cs | 4 ++++ src/Tizen.NUI/src/internal/ObjectRegistry.cs | 4 ++++ src/Tizen.NUI/src/internal/PathConstrainer.cs | 4 ++++ src/Tizen.NUI/src/internal/PropertyCondition.cs | 4 ++++ src/Tizen.NUI/src/internal/PropertyNotification.cs | 4 ++++ src/Tizen.NUI/src/internal/RenderTaskList.cs | 4 ++++ src/Tizen.NUI/src/internal/TypeRegistry.cs | 4 ++++ src/Tizen.NUI/src/public/Animatable.cs | 4 ++++ src/Tizen.NUI/src/public/Animation.cs | 4 ++++ src/Tizen.NUI/src/public/BaseComponents/Scrollable.cs | 4 ++++ src/Tizen.NUI/src/public/BaseComponents/TableView.cs | 4 ++++ src/Tizen.NUI/src/public/BaseComponents/TextEditor.cs | 4 ++++ src/Tizen.NUI/src/public/BaseComponents/TextField.cs | 4 ++++ src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs | 4 ++++ src/Tizen.NUI/src/public/BaseComponents/VideoView.cs | 4 ++++ src/Tizen.NUI/src/public/BaseComponents/View.cs | 4 ++++ src/Tizen.NUI/src/public/BaseHandle.cs | 7 ++++--- src/Tizen.NUI/src/public/FocusManager.cs | 4 ++++ src/Tizen.NUI/src/public/Geometry.cs | 4 ++++ src/Tizen.NUI/src/public/ImfManager.cs | 4 ++++ src/Tizen.NUI/src/public/KeyFrames.cs | 4 ++++ src/Tizen.NUI/src/public/Layer.cs | 4 ++++ src/Tizen.NUI/src/public/Path.cs | 4 ++++ src/Tizen.NUI/src/public/PixelData.cs | 4 ++++ src/Tizen.NUI/src/public/PropertyBuffer.cs | 4 ++++ src/Tizen.NUI/src/public/Renderer.cs | 4 ++++ src/Tizen.NUI/src/public/Sampler.cs | 4 ++++ src/Tizen.NUI/src/public/ScrollViewEffect.cs | 4 ++++ src/Tizen.NUI/src/public/Shader.cs | 4 ++++ src/Tizen.NUI/src/public/StyleManager.cs | 4 ++++ src/Tizen.NUI/src/public/TTSPlayer.cs | 4 ++++ src/Tizen.NUI/src/public/Texture.cs | 4 ++++ src/Tizen.NUI/src/public/TextureSet.cs | 4 ++++ src/Tizen.NUI/src/public/Timer.cs | 4 ++++ src/Tizen.NUI/src/public/Touch.cs | 4 ++++ src/Tizen.NUI/src/public/TransitionData.cs | 4 ++++ src/Tizen.NUI/src/public/TypeInfo.cs | 4 ++++ src/Tizen.NUI/src/public/UIComponents/Button.cs | 4 ++++ src/Tizen.NUI/src/public/UIComponents/CheckBoxButton.cs | 4 ++++ src/Tizen.NUI/src/public/UIComponents/Popup.cs | 4 ++++ src/Tizen.NUI/src/public/UIComponents/ProgressBar.cs | 4 ++++ src/Tizen.NUI/src/public/UIComponents/PushButton.cs | 4 ++++ src/Tizen.NUI/src/public/UIComponents/RadioButton.cs | 4 ++++ src/Tizen.NUI/src/public/UIComponents/ScrollBar.cs | 4 ++++ src/Tizen.NUI/src/public/UIComponents/ScrollView.cs | 4 ++++ src/Tizen.NUI/src/public/UIComponents/Slider.cs | 4 ++++ src/Tizen.NUI/src/public/UIComponents/ToggleButton.cs | 4 ++++ src/Tizen.NUI/src/public/ViewWrapper.cs | 4 ++++ src/Tizen.NUI/src/public/VisualBase.cs | 4 ++++ src/Tizen.NUI/src/public/VisualFactory.cs | 4 ++++ src/Tizen.NUI/src/public/Window.cs | 4 ++++ 67 files changed, 268 insertions(+), 4 deletions(-) diff --git a/src/Tizen.NUI/src/internal/AccessibilityManager.cs b/src/Tizen.NUI/src/internal/AccessibilityManager.cs index 2fc7605..969b8ee 100755 --- a/src/Tizen.NUI/src/internal/AccessibilityManager.cs +++ b/src/Tizen.NUI/src/internal/AccessibilityManager.cs @@ -59,6 +59,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_AccessibilityManager(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/Alignment.cs b/src/Tizen.NUI/src/internal/Alignment.cs index e64520e..d2f2199 100755 --- a/src/Tizen.NUI/src/internal/Alignment.cs +++ b/src/Tizen.NUI/src/internal/Alignment.cs @@ -57,6 +57,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Alignment(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/Application.cs b/src/Tizen.NUI/src/internal/Application.cs index 405f9f2..75e1996 100755 --- a/src/Tizen.NUI/src/internal/Application.cs +++ b/src/Tizen.NUI/src/internal/Application.cs @@ -351,6 +351,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Application(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/AsyncImageLoader.cs b/src/Tizen.NUI/src/internal/AsyncImageLoader.cs index f3f122d..0e90c9d 100755 --- a/src/Tizen.NUI/src/internal/AsyncImageLoader.cs +++ b/src/Tizen.NUI/src/internal/AsyncImageLoader.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_AsyncImageLoader(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/BufferImage.cs b/src/Tizen.NUI/src/internal/BufferImage.cs index 0db41cf..c20c32b 100755 --- a/src/Tizen.NUI/src/internal/BufferImage.cs +++ b/src/Tizen.NUI/src/internal/BufferImage.cs @@ -56,6 +56,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_BufferImage(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/Builder.cs b/src/Tizen.NUI/src/internal/Builder.cs index b826f65..8e8d2f0 100755 --- a/src/Tizen.NUI/src/internal/Builder.cs +++ b/src/Tizen.NUI/src/internal/Builder.cs @@ -55,12 +55,15 @@ namespace Tizen.NUI //You should not access any managed member here except static instance. //because the execution order of Finalizes is non-deterministic. - if (swigCPtr.Handle != global::System.IntPtr.Zero) { if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Builder(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/Camera.cs b/src/Tizen.NUI/src/internal/Camera.cs index 7f98d94..4bea2ed 100755 --- a/src/Tizen.NUI/src/internal/Camera.cs +++ b/src/Tizen.NUI/src/internal/Camera.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_CameraActor(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/CustomActor.cs b/src/Tizen.NUI/src/internal/CustomActor.cs index 8bea2d1..6855c2d 100755 --- a/src/Tizen.NUI/src/internal/CustomActor.cs +++ b/src/Tizen.NUI/src/internal/CustomActor.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_CustomActor(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/DragAndDropDetector.cs b/src/Tizen.NUI/src/internal/DragAndDropDetector.cs index 5861ba3..886ecfb 100755 --- a/src/Tizen.NUI/src/internal/DragAndDropDetector.cs +++ b/src/Tizen.NUI/src/internal/DragAndDropDetector.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_DragAndDropDetector(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/EncodedBufferImage.cs b/src/Tizen.NUI/src/internal/EncodedBufferImage.cs index 6f801c7..49f7017 100755 --- a/src/Tizen.NUI/src/internal/EncodedBufferImage.cs +++ b/src/Tizen.NUI/src/internal/EncodedBufferImage.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_EncodedBufferImage(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/FrameBuffer.cs b/src/Tizen.NUI/src/internal/FrameBuffer.cs index aba063a..5673499 100755 --- a/src/Tizen.NUI/src/internal/FrameBuffer.cs +++ b/src/Tizen.NUI/src/internal/FrameBuffer.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_FrameBuffer(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/FrameBufferImage.cs b/src/Tizen.NUI/src/internal/FrameBufferImage.cs index 3646b8a..387d3aa 100755 --- a/src/Tizen.NUI/src/internal/FrameBufferImage.cs +++ b/src/Tizen.NUI/src/internal/FrameBufferImage.cs @@ -56,6 +56,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_FrameBufferImage(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/GaussianBlurView.cs b/src/Tizen.NUI/src/internal/GaussianBlurView.cs index b9e2cdd..a19ae3e 100755 --- a/src/Tizen.NUI/src/internal/GaussianBlurView.cs +++ b/src/Tizen.NUI/src/internal/GaussianBlurView.cs @@ -61,6 +61,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_GaussianBlurView(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/GestureDetector.cs b/src/Tizen.NUI/src/internal/GestureDetector.cs index faf27a3..8744b13 100755 --- a/src/Tizen.NUI/src/internal/GestureDetector.cs +++ b/src/Tizen.NUI/src/internal/GestureDetector.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_GestureDetector(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/Image.cs b/src/Tizen.NUI/src/internal/Image.cs index af70862..408fb6b 100755 --- a/src/Tizen.NUI/src/internal/Image.cs +++ b/src/Tizen.NUI/src/internal/Image.cs @@ -59,6 +59,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Image(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/KeyInputFocusManager.cs b/src/Tizen.NUI/src/internal/KeyInputFocusManager.cs index dd6f093..624ec10 100755 --- a/src/Tizen.NUI/src/internal/KeyInputFocusManager.cs +++ b/src/Tizen.NUI/src/internal/KeyInputFocusManager.cs @@ -57,6 +57,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_KeyInputFocusManager(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/LinearConstrainer.cs b/src/Tizen.NUI/src/internal/LinearConstrainer.cs index 6004eb0..009eba6 100755 --- a/src/Tizen.NUI/src/internal/LinearConstrainer.cs +++ b/src/Tizen.NUI/src/internal/LinearConstrainer.cs @@ -56,6 +56,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_LinearConstrainer(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/ObjectRegistry.cs b/src/Tizen.NUI/src/internal/ObjectRegistry.cs index 5051c31..3e2f99a 100755 --- a/src/Tizen.NUI/src/internal/ObjectRegistry.cs +++ b/src/Tizen.NUI/src/internal/ObjectRegistry.cs @@ -59,6 +59,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_ObjectRegistry(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/PathConstrainer.cs b/src/Tizen.NUI/src/internal/PathConstrainer.cs index 9abb448..e46ca02 100755 --- a/src/Tizen.NUI/src/internal/PathConstrainer.cs +++ b/src/Tizen.NUI/src/internal/PathConstrainer.cs @@ -56,6 +56,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_PathConstrainer(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/PropertyCondition.cs b/src/Tizen.NUI/src/internal/PropertyCondition.cs index 278349f..d6673d6 100755 --- a/src/Tizen.NUI/src/internal/PropertyCondition.cs +++ b/src/Tizen.NUI/src/internal/PropertyCondition.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_PropertyCondition(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/PropertyNotification.cs b/src/Tizen.NUI/src/internal/PropertyNotification.cs index d084ca1..0610108 100755 --- a/src/Tizen.NUI/src/internal/PropertyNotification.cs +++ b/src/Tizen.NUI/src/internal/PropertyNotification.cs @@ -59,6 +59,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_PropertyNotification(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/RenderTaskList.cs b/src/Tizen.NUI/src/internal/RenderTaskList.cs index 250ba24..11facae 100755 --- a/src/Tizen.NUI/src/internal/RenderTaskList.cs +++ b/src/Tizen.NUI/src/internal/RenderTaskList.cs @@ -56,6 +56,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_RenderTaskList(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/internal/TypeRegistry.cs b/src/Tizen.NUI/src/internal/TypeRegistry.cs index 2ac7953..647d924 100755 --- a/src/Tizen.NUI/src/internal/TypeRegistry.cs +++ b/src/Tizen.NUI/src/internal/TypeRegistry.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_TypeRegistry(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Animatable.cs b/src/Tizen.NUI/src/public/Animatable.cs index 578477f..a718fb8 100755 --- a/src/Tizen.NUI/src/public/Animatable.cs +++ b/src/Tizen.NUI/src/public/Animatable.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Handle(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Animation.cs b/src/Tizen.NUI/src/public/Animation.cs index d999316..451cffe 100755 --- a/src/Tizen.NUI/src/public/Animation.cs +++ b/src/Tizen.NUI/src/public/Animation.cs @@ -70,6 +70,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Animation(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/BaseComponents/Scrollable.cs b/src/Tizen.NUI/src/public/BaseComponents/Scrollable.cs index 37b8cfd..291626d 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/Scrollable.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/Scrollable.cs @@ -58,6 +58,10 @@ namespace Tizen.NUI.BaseComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Scrollable(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/BaseComponents/TableView.cs b/src/Tizen.NUI/src/public/BaseComponents/TableView.cs index 5744fc0..b8e3015 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/TableView.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/TableView.cs @@ -62,6 +62,10 @@ namespace Tizen.NUI.BaseComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_TableView(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/BaseComponents/TextEditor.cs b/src/Tizen.NUI/src/public/BaseComponents/TextEditor.cs index 6900bc4..a651298 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/TextEditor.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/TextEditor.cs @@ -63,6 +63,10 @@ namespace Tizen.NUI.BaseComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_TextEditor(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/BaseComponents/TextField.cs b/src/Tizen.NUI/src/public/BaseComponents/TextField.cs index 7bb8f3f..5703250 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/TextField.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/TextField.cs @@ -64,6 +64,10 @@ namespace Tizen.NUI.BaseComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_TextField(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs b/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs index bc794d7..eaf3973 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/TextLabel.cs @@ -63,6 +63,10 @@ namespace Tizen.NUI.BaseComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_TextLabel(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/BaseComponents/VideoView.cs b/src/Tizen.NUI/src/public/BaseComponents/VideoView.cs index 7c380b9..bf20336 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/VideoView.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/VideoView.cs @@ -60,6 +60,10 @@ namespace Tizen.NUI.BaseComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_VideoView(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/BaseComponents/View.cs b/src/Tizen.NUI/src/public/BaseComponents/View.cs index 100800a..4800111 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/View.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/View.cs @@ -64,6 +64,10 @@ namespace Tizen.NUI.BaseComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_View(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/BaseHandle.cs b/src/Tizen.NUI/src/public/BaseHandle.cs index 8ac41e0..848b995 100755 --- a/src/Tizen.NUI/src/public/BaseHandle.cs +++ b/src/Tizen.NUI/src/public/BaseHandle.cs @@ -88,14 +88,15 @@ namespace Tizen.NUI //You should not access any managed member here except static instance. //because the execution order of Finalizes is non-deterministic. - //Unreference this instance from Registry. - Registry.Unregister(this); - if (swigCPtr.Handle != global::System.IntPtr.Zero) { if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_BaseHandle(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/FocusManager.cs b/src/Tizen.NUI/src/public/FocusManager.cs index 8eb6116..f93a471 100755 --- a/src/Tizen.NUI/src/public/FocusManager.cs +++ b/src/Tizen.NUI/src/public/FocusManager.cs @@ -70,6 +70,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicManualPINVOKE.delete_FocusManager(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Geometry.cs b/src/Tizen.NUI/src/public/Geometry.cs index 4752be2..2fc19a5 100755 --- a/src/Tizen.NUI/src/public/Geometry.cs +++ b/src/Tizen.NUI/src/public/Geometry.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Geometry(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/ImfManager.cs b/src/Tizen.NUI/src/public/ImfManager.cs index a1234e4..34122ea 100755 --- a/src/Tizen.NUI/src/public/ImfManager.cs +++ b/src/Tizen.NUI/src/public/ImfManager.cs @@ -58,6 +58,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicManualPINVOKE.delete_ImfManager(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/KeyFrames.cs b/src/Tizen.NUI/src/public/KeyFrames.cs index 8b58ce5..16382da 100755 --- a/src/Tizen.NUI/src/public/KeyFrames.cs +++ b/src/Tizen.NUI/src/public/KeyFrames.cs @@ -60,6 +60,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_KeyFrames(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Layer.cs b/src/Tizen.NUI/src/public/Layer.cs index 84daa09..6bef8bf 100755 --- a/src/Tizen.NUI/src/public/Layer.cs +++ b/src/Tizen.NUI/src/public/Layer.cs @@ -59,6 +59,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Layer(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Path.cs b/src/Tizen.NUI/src/public/Path.cs index 4090eaa..603eb14 100755 --- a/src/Tizen.NUI/src/public/Path.cs +++ b/src/Tizen.NUI/src/public/Path.cs @@ -60,6 +60,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Path(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/PixelData.cs b/src/Tizen.NUI/src/public/PixelData.cs index 0b8f7a8..5837ebf 100755 --- a/src/Tizen.NUI/src/public/PixelData.cs +++ b/src/Tizen.NUI/src/public/PixelData.cs @@ -56,6 +56,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_PixelData(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/PropertyBuffer.cs b/src/Tizen.NUI/src/public/PropertyBuffer.cs index bbbb2b8..fd8b66e 100755 --- a/src/Tizen.NUI/src/public/PropertyBuffer.cs +++ b/src/Tizen.NUI/src/public/PropertyBuffer.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_PropertyBuffer(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Renderer.cs b/src/Tizen.NUI/src/public/Renderer.cs index d875000..9db89a9 100755 --- a/src/Tizen.NUI/src/public/Renderer.cs +++ b/src/Tizen.NUI/src/public/Renderer.cs @@ -56,6 +56,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Renderer(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Sampler.cs b/src/Tizen.NUI/src/public/Sampler.cs index c1ed5ed..bccaec9 100755 --- a/src/Tizen.NUI/src/public/Sampler.cs +++ b/src/Tizen.NUI/src/public/Sampler.cs @@ -56,6 +56,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Sampler(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/ScrollViewEffect.cs b/src/Tizen.NUI/src/public/ScrollViewEffect.cs index 89d9762..bfb887a 100755 --- a/src/Tizen.NUI/src/public/ScrollViewEffect.cs +++ b/src/Tizen.NUI/src/public/ScrollViewEffect.cs @@ -56,6 +56,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_ScrollViewEffect(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Shader.cs b/src/Tizen.NUI/src/public/Shader.cs index 317e9ce..34cba58 100755 --- a/src/Tizen.NUI/src/public/Shader.cs +++ b/src/Tizen.NUI/src/public/Shader.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Shader(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/StyleManager.cs b/src/Tizen.NUI/src/public/StyleManager.cs index 960b5f4..441f4ba 100755 --- a/src/Tizen.NUI/src/public/StyleManager.cs +++ b/src/Tizen.NUI/src/public/StyleManager.cs @@ -68,6 +68,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_StyleManager(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/TTSPlayer.cs b/src/Tizen.NUI/src/public/TTSPlayer.cs index ec2b788..4acfe54 100755 --- a/src/Tizen.NUI/src/public/TTSPlayer.cs +++ b/src/Tizen.NUI/src/public/TTSPlayer.cs @@ -59,6 +59,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicManualPINVOKE.delete_TtsPlayer(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Texture.cs b/src/Tizen.NUI/src/public/Texture.cs index 2503ca5..9f58433 100755 --- a/src/Tizen.NUI/src/public/Texture.cs +++ b/src/Tizen.NUI/src/public/Texture.cs @@ -56,6 +56,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Texture(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/TextureSet.cs b/src/Tizen.NUI/src/public/TextureSet.cs index c7ee739..f2a09ee 100755 --- a/src/Tizen.NUI/src/public/TextureSet.cs +++ b/src/Tizen.NUI/src/public/TextureSet.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_TextureSet(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Timer.cs b/src/Tizen.NUI/src/public/Timer.cs index 8229740..14ceeda 100755 --- a/src/Tizen.NUI/src/public/Timer.cs +++ b/src/Tizen.NUI/src/public/Timer.cs @@ -67,6 +67,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Timer(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Touch.cs b/src/Tizen.NUI/src/public/Touch.cs index a547720..601f58f 100755 --- a/src/Tizen.NUI/src/public/Touch.cs +++ b/src/Tizen.NUI/src/public/Touch.cs @@ -59,6 +59,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Touch(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/TransitionData.cs b/src/Tizen.NUI/src/public/TransitionData.cs index b3611a0..0a86cc2 100755 --- a/src/Tizen.NUI/src/public/TransitionData.cs +++ b/src/Tizen.NUI/src/public/TransitionData.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_TransitionData(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/TypeInfo.cs b/src/Tizen.NUI/src/public/TypeInfo.cs index 0583ffe..7773fa4 100755 --- a/src/Tizen.NUI/src/public/TypeInfo.cs +++ b/src/Tizen.NUI/src/public/TypeInfo.cs @@ -55,6 +55,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_TypeInfo(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/UIComponents/Button.cs b/src/Tizen.NUI/src/public/UIComponents/Button.cs index a67858d..430471f 100755 --- a/src/Tizen.NUI/src/public/UIComponents/Button.cs +++ b/src/Tizen.NUI/src/public/UIComponents/Button.cs @@ -77,6 +77,10 @@ namespace Tizen.NUI.UIComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Button(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/UIComponents/CheckBoxButton.cs b/src/Tizen.NUI/src/public/UIComponents/CheckBoxButton.cs index e2ef38a..ea094b8 100755 --- a/src/Tizen.NUI/src/public/UIComponents/CheckBoxButton.cs +++ b/src/Tizen.NUI/src/public/UIComponents/CheckBoxButton.cs @@ -68,6 +68,10 @@ namespace Tizen.NUI.UIComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_CheckBoxButton(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/UIComponents/Popup.cs b/src/Tizen.NUI/src/public/UIComponents/Popup.cs index 1a933a4..395ab74 100755 --- a/src/Tizen.NUI/src/public/UIComponents/Popup.cs +++ b/src/Tizen.NUI/src/public/UIComponents/Popup.cs @@ -63,6 +63,10 @@ namespace Tizen.NUI.UIComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Popup(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/UIComponents/ProgressBar.cs b/src/Tizen.NUI/src/public/UIComponents/ProgressBar.cs index 978e777..6ec9d15 100755 --- a/src/Tizen.NUI/src/public/UIComponents/ProgressBar.cs +++ b/src/Tizen.NUI/src/public/UIComponents/ProgressBar.cs @@ -65,6 +65,10 @@ namespace Tizen.NUI.UIComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_ProgressBar(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/UIComponents/PushButton.cs b/src/Tizen.NUI/src/public/UIComponents/PushButton.cs index 39bd34c..8352dcd 100755 --- a/src/Tizen.NUI/src/public/UIComponents/PushButton.cs +++ b/src/Tizen.NUI/src/public/UIComponents/PushButton.cs @@ -63,6 +63,10 @@ namespace Tizen.NUI.UIComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_PushButton(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/UIComponents/RadioButton.cs b/src/Tizen.NUI/src/public/UIComponents/RadioButton.cs index d082422..a6babcf 100755 --- a/src/Tizen.NUI/src/public/UIComponents/RadioButton.cs +++ b/src/Tizen.NUI/src/public/UIComponents/RadioButton.cs @@ -71,6 +71,10 @@ namespace Tizen.NUI.UIComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_RadioButton(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/UIComponents/ScrollBar.cs b/src/Tizen.NUI/src/public/UIComponents/ScrollBar.cs index d1d619f..6b02b69 100755 --- a/src/Tizen.NUI/src/public/UIComponents/ScrollBar.cs +++ b/src/Tizen.NUI/src/public/UIComponents/ScrollBar.cs @@ -65,6 +65,10 @@ namespace Tizen.NUI.UIComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_ScrollBar(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/UIComponents/ScrollView.cs b/src/Tizen.NUI/src/public/UIComponents/ScrollView.cs index b9bb7ea..c84a51f 100755 --- a/src/Tizen.NUI/src/public/UIComponents/ScrollView.cs +++ b/src/Tizen.NUI/src/public/UIComponents/ScrollView.cs @@ -59,6 +59,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_ScrollView(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/UIComponents/Slider.cs b/src/Tizen.NUI/src/public/UIComponents/Slider.cs index 6783fe0..258fb58 100755 --- a/src/Tizen.NUI/src/public/UIComponents/Slider.cs +++ b/src/Tizen.NUI/src/public/UIComponents/Slider.cs @@ -65,6 +65,10 @@ namespace Tizen.NUI.UIComponents if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Slider(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/UIComponents/ToggleButton.cs b/src/Tizen.NUI/src/public/UIComponents/ToggleButton.cs index fe3eef4..62f0890 100755 --- a/src/Tizen.NUI/src/public/UIComponents/ToggleButton.cs +++ b/src/Tizen.NUI/src/public/UIComponents/ToggleButton.cs @@ -57,6 +57,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_ToggleButton(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/ViewWrapper.cs b/src/Tizen.NUI/src/public/ViewWrapper.cs index f931357..a89fcd3 100755 --- a/src/Tizen.NUI/src/public/ViewWrapper.cs +++ b/src/Tizen.NUI/src/public/ViewWrapper.cs @@ -58,6 +58,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicManualPINVOKE.delete_ViewWrapper(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/VisualBase.cs b/src/Tizen.NUI/src/public/VisualBase.cs index 42311b1..ffb947a 100755 --- a/src/Tizen.NUI/src/public/VisualBase.cs +++ b/src/Tizen.NUI/src/public/VisualBase.cs @@ -59,6 +59,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_VisualBase(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/VisualFactory.cs b/src/Tizen.NUI/src/public/VisualFactory.cs index 9c6e7c2..ae2a6e8 100755 --- a/src/Tizen.NUI/src/public/VisualFactory.cs +++ b/src/Tizen.NUI/src/public/VisualFactory.cs @@ -57,6 +57,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_VisualFactory(swigCPtr); } swigCPtr = new global::System.Runtime.InteropServices.HandleRef(null, global::System.IntPtr.Zero); diff --git a/src/Tizen.NUI/src/public/Window.cs b/src/Tizen.NUI/src/public/Window.cs index 7a610fd..70039ec 100755 --- a/src/Tizen.NUI/src/public/Window.cs +++ b/src/Tizen.NUI/src/public/Window.cs @@ -70,6 +70,10 @@ namespace Tizen.NUI if (swigCMemOwn) { swigCMemOwn = false; + + //Unreference this instance from Registry. + Registry.Unregister(this); + NDalicPINVOKE.delete_Window(swigCPtr); NDalicPINVOKE.delete_Stage(stageCPtr); } -- 2.7.4