From a7503152fdb9c865633bd8aeebf02c0fe4e158fa Mon Sep 17 00:00:00 2001 From: "joogab.yun" Date: Wed, 17 Jul 2024 15:21:07 +0900 Subject: [PATCH] Revert "[NUI] If the view had focus when it was unparented, the focus is cleared. (#4654)" This reverts commit 09f52bc8bdea3e4e50b610c0b6bc18b54104feb4. This operation is moved to the DALi. https://review.tizen.org/gerrit/#/c/platform/core/uifw/dali-toolkit/+/314664/ --- src/Tizen.NUI/src/public/BaseComponents/ViewInternal.cs | 6 ------ src/Tizen.NUI/src/public/Common/Layer.cs | 6 ------ 2 files changed, 12 deletions(-) diff --git a/src/Tizen.NUI/src/public/BaseComponents/ViewInternal.cs b/src/Tizen.NUI/src/public/BaseComponents/ViewInternal.cs index 34e7735..9513811 100755 --- a/src/Tizen.NUI/src/public/BaseComponents/ViewInternal.cs +++ b/src/Tizen.NUI/src/public/BaseComponents/ViewInternal.cs @@ -1144,12 +1144,6 @@ namespace Tizen.NUI.BaseComponents internal void RemoveChild(View child) { - // If the view had focus, it clears focus. - if (child == FocusManager.Instance.GetCurrentFocusView()) - { - Tizen.Log.Debug("NUI", $"ClearFocus due to View id:({child.ID}) removed from scene\n"); - FocusManager.Instance.ClearFocus(); - } // Do actual child removal Interop.Actor.Remove(SwigCPtr, View.getCPtr(child)); if (NDalicPINVOKE.SWIGPendingException.Pending) diff --git a/src/Tizen.NUI/src/public/Common/Layer.cs b/src/Tizen.NUI/src/public/Common/Layer.cs index 828ba47..eadf021 100755 --- a/src/Tizen.NUI/src/public/Common/Layer.cs +++ b/src/Tizen.NUI/src/public/Common/Layer.cs @@ -348,12 +348,6 @@ namespace Tizen.NUI Tizen.Log.Error("NUI", "You have deleted a view that is not a child of this layer."); return; } - // If the view had focus, it clears focus. - if (child == FocusManager.Instance.GetCurrentFocusView()) - { - FocusManager.Instance.ClearFocus(); - } - Interop.Actor.Remove(SwigCPtr, View.getCPtr(child)); if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve(); -- 2.7.4