From b00f9643a9b562d0d437e9e7c9c465ddc770b929 Mon Sep 17 00:00:00 2001 From: "Eunki, Hong" Date: Mon, 10 Jun 2024 16:21:36 +0900 Subject: [PATCH] [NUI][API11] Fix memory leak when DragAndDrop try to get Position Since DragEvent's GetPosition return new Vector2 class internally, we should keep the positoin with memory ownership. Signed-off-by: Eunki, Hong --- src/Tizen.NUI/src/public/DragAndDrop/DragAndDrop.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Tizen.NUI/src/public/DragAndDrop/DragAndDrop.cs b/src/Tizen.NUI/src/public/DragAndDrop/DragAndDrop.cs index 2d3ae18..c2ad8a3 100755 --- a/src/Tizen.NUI/src/public/DragAndDrop/DragAndDrop.cs +++ b/src/Tizen.NUI/src/public/DragAndDrop/DragAndDrop.cs @@ -189,7 +189,7 @@ namespace Tizen.NUI DragType type = (DragType)Interop.DragAndDrop.GetAction(dragEvent); DragEvent ev = new DragEvent(); global::System.IntPtr cPtr = Interop.DragAndDrop.GetPosition(dragEvent); - ev.Position = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, false); + ev.Position = (cPtr == global::System.IntPtr.Zero) ? null : new Position(cPtr, true); if (type == DragType.Enter) { -- 2.7.4