From: tscholb Date: Wed, 25 Sep 2019 07:06:10 +0000 (+0900) Subject: [NUI] Modify GetWindowList for getting Native Ptr (#1037) X-Git-Tag: submit/tizen/20190926.005204~1^2~1 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=5cc361123465e81e17efe13bfd37d6472c61590b;p=platform%2Fcore%2Fcsapi%2Ftizenfx.git [NUI] Modify GetWindowList for getting Native Ptr (#1037) - Modify GetWindowList for getting Native Ptr - Set Window name when creating window using window name --- diff --git a/src/Tizen.NUI/src/internal/Application.cs b/src/Tizen.NUI/src/internal/Application.cs index 228492c28..215171f8e 100755 --- a/src/Tizen.NUI/src/internal/Application.cs +++ b/src/Tizen.NUI/src/internal/Application.cs @@ -1381,9 +1381,12 @@ namespace Tizen.NUI List WindowList = new List(); for( uint i = 0; i < ListSize; ++i ) { - Window currWin = new Window(Interop.Application.Application_GetWindowsFromList(i), true); + Window currWin = Registry.GetManagedBaseHandleFromNativePtr(Interop.Application.Application_GetWindowsFromList(i)) as Window; if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); - WindowList.Add(currWin); + if(currWin) + { + WindowList.Add(currWin); + } } return WindowList; } diff --git a/src/Tizen.NUI/src/public/Window.cs b/src/Tizen.NUI/src/public/Window.cs index 10710b52a..bf6af72d8 100755 --- a/src/Tizen.NUI/src/public/Window.cs +++ b/src/Tizen.NUI/src/public/Window.cs @@ -90,6 +90,7 @@ namespace Tizen.NUI /// 6 public Window(string name, Rectangle windowPosition = null, bool isTranslucent = false) : this(Interop.Window.Window_New__SWIG_0(Rectangle.getCPtr(windowPosition), name, isTranslucent), true) { + this._windowTitle = name; if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); }