[NUI] Binding EnableFocusIndicator and IsFocusIndicatorEnabled
authorjoogab.yun <joogab.yun@samsung.com>
Wed, 3 May 2023 05:17:00 +0000 (14:17 +0900)
committerdongsug-song <35130733+dongsug-song@users.noreply.github.com>
Mon, 22 May 2023 10:12:20 +0000 (19:12 +0900)
refer : https://review.tizen.org/gerrit/#/c/platform/core/uifw/dali-csharp-binder/+/292280/

src/Tizen.NUI/src/internal/Interop/Interop.FocusManager.cs
src/Tizen.NUI/src/public/Input/FocusManager.cs

index f13184cad3976001e4918e3f64a21e01282338f0..b184d81b7db959474d6f9dbcfd582d26ea40f335 100755 (executable)
@@ -102,6 +102,13 @@ namespace Tizen.NUI
             [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_Dali_KeyboardFocusManager_ResetFocusFinderRootActor")]
             public static extern void ResetFocusFinderRootView(global::System.Runtime.InteropServices.HandleRef jarg1);
 
+            [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_KeyboardFocusManager_EnableFocusIndicator")]
+            public static extern void EnableFocusIndicator(global::System.Runtime.InteropServices.HandleRef focusManager, bool enable);
+
+            [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_KeyboardFocusManager_IsFocusIndicatorEnabled")]
+            [return: global::System.Runtime.InteropServices.MarshalAs(global::System.Runtime.InteropServices.UnmanagedType.U1)]
+            public static extern bool IsFocusIndicatorEnabled(global::System.Runtime.InteropServices.HandleRef focusManager);
+
             [global::System.Runtime.InteropServices.DllImport(NDalicPINVOKE.Lib, EntryPoint = "CSharp_KeyboardFocusManager_SWIGUpcast")]
             public static extern global::System.IntPtr Upcast(global::System.IntPtr jarg1);
         }
index ed2a92f9566142d66e3708a8b822738743edc615..d43f75b22a651a5738348ddfbf3b76252844072c 100755 (executable)
@@ -542,6 +542,29 @@ namespace Tizen.NUI
             if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
         }
 
+        /// <summary>
+        /// Decide using focus indicator or not
+        /// </summary>
+        /// <param name="enable">Whether using focus indicator or not</param>
+        [EditorBrowsable(EditorBrowsableState.Never)]
+        public void EnableFocusIndicator(bool enable)
+        {
+            Interop.FocusManager.EnableFocusIndicator(SwigCPtr, enable);
+            if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+        }
+
+        /// <summary>
+        /// Check focus indicator is enabled or not
+        /// </summary>
+        /// <returns>Whether focus indicator is enabled</returns>
+        [EditorBrowsable(EditorBrowsableState.Never)]
+        public bool IsFocusIndicatorEnabled()
+        {
+            bool ret = Interop.FocusManager.IsFocusIndicatorEnabled(SwigCPtr);
+            if (NDalicPINVOKE.SWIGPendingException.Pending) throw NDalicPINVOKE.SWIGPendingException.Retrieve();
+            return ret;
+        }
+
         /// <summary>
         /// Get a default focus indicator
         /// </summary>