[TCSACR-598][InputMethod] Remove deprecated APIs (#6313)
authorInhong <inhong1.han@samsung.com>
Thu, 12 Sep 2024 09:04:54 +0000 (18:04 +0900)
committerGitHub <noreply@github.com>
Thu, 12 Sep 2024 09:04:54 +0000 (18:04 +0900)
src/Tizen.Uix.InputMethod/Interop/Interop.InputMethod.cs
src/Tizen.Uix.InputMethod/Tizen.Uix.InputMethod.csproj
src/Tizen.Uix.InputMethod/Tizen.Uix.InputMethod/EditorWindow.cs [deleted file]
src/Tizen.Uix.InputMethod/Tizen.Uix.InputMethod/InputMethodEditor.cs

index fab0f67b45f6ad7a85d91c88218c56c0f2643813..f1dab944d0b487ceb8bedf695ca0adebea101eb5 100644 (file)
@@ -201,9 +201,6 @@ internal static partial class Interop
         [DllImport(Libraries.InputMethod, EntryPoint = "ime_set_selection")]
         internal static extern ErrorCode ImeSetSelection(int start, int end);
 
-        [DllImport(Libraries.InputMethod, EntryPoint = "ime_get_main_window")]
-        internal static extern IntPtr ImeGetMainWindow();
-
         [DllImport(Libraries.InputMethod, EntryPoint = "ime_request_hide")]
         internal static extern ErrorCode ImeRequestHide();
 
@@ -219,9 +216,6 @@ internal static partial class Interop
         [DllImport(Libraries.InputMethod, EntryPoint = "ime_set_dotnet_flag")]
         internal static extern ErrorCode ImeSetDotnetFlag(bool set);
 
-        [DllImport(Libraries.InputMethod, EntryPoint = "ime_set_size")]
-        internal static extern ErrorCode ImeSetSize(int portraitWidth, int portraitHeight, int landscapeWidth, int landscapeHeight);
-
         [DllImport(Libraries.InputMethod, EntryPoint = "ime_context_get_layout")]
         internal static extern ErrorCode ImeContextGetLayout(IntPtr context, out InputPanelLayout layout);
 
index feac9a6af4f20c889cf9fa2476603e2640c9ca79..d82d90a7dd410d131c367fb04f8222c3783f8493 100644 (file)
@@ -7,7 +7,6 @@
   <ItemGroup>
     <ProjectReference Include="..\Tizen\Tizen.csproj" />
     <ProjectReference Include="..\Tizen.Log\Tizen.Log.csproj" />
-    <ProjectReference Include="..\ElmSharp\ElmSharp.csproj" />
   </ItemGroup>
 
 </Project>
diff --git a/src/Tizen.Uix.InputMethod/Tizen.Uix.InputMethod/EditorWindow.cs b/src/Tizen.Uix.InputMethod/Tizen.Uix.InputMethod/EditorWindow.cs
deleted file mode 100755 (executable)
index 8b1fc6c..0000000
+++ /dev/null
@@ -1,87 +0,0 @@
-/*
-* Copyright (c) 2016 Samsung Electronics Co., Ltd All Rights Reserved
-*
-* Licensed under the Apache License, Version 2.0 (the License);
-* you may not use this file except in compliance with the License.
-* You may obtain a copy of the License at
-*
-* http://www.apache.org/licenses/LICENSE-2.0
-*
-* Unless required by applicable law or agreed to in writing, software
-* distributed under the License is distributed on an AS IS BASIS,
-* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
-* See the License for the specific language governing permissions and
-* limitations under the License.
-*/
-
-using Tizen;
-using System;
-using ElmSharp;
-using static Interop.InputMethod;
-
-namespace Tizen.Uix.InputMethod
-{
-    /// <summary>
-    /// The editor window class.
-    /// </summary>
-    /// <since_tizen> 4 </since_tizen>
-    [Obsolete("Deprecated since API10. Will be removed in API12. Use NUIApplication.GetDefaultWindow() to get window in NUI application")]
-    public class EditorWindow : Window
-    {
-        internal static IntPtr _handle = IntPtr.Zero;
-        private IntPtr _realHandle = IntPtr.Zero;
-
-        internal EditorWindow():base("Edit")
-        {
-            _realHandle = _handle;
-        }
-
-        /// <summary>
-        /// This API creates a handle for the editor window.
-        /// </summary>
-        /// <param name="parent">Parent EvasObject.</param>
-        /// <returns>Handle IntPtr.</returns>
-        /// <since_tizen> 4 </since_tizen>
-        [Obsolete("Deprecated since API10. Will be removed in API12.")]
-        protected override IntPtr CreateHandle(EvasObject parent)
-        {
-            return _handle;
-        }
-
-        /// <summary>
-        /// This API gets a handle for the editor window.
-        /// </summary>
-        /// <returns>Handle IntPtr.</returns>
-        /// <since_tizen> 4 </since_tizen>
-        [Obsolete("Deprecated since API10. Will be removed in API12.")]
-        public IntPtr GetHandle()
-        {
-            return _handle;
-        }
-
-        /// <summary>
-        /// This API updates the input panel window's size information.
-        /// </summary>
-        /// <privilege>
-        /// http://tizen.org/privilege/ime
-        /// </privilege>
-        /// <param name="portraitWidth">The width in the portrait mode.</param>
-        /// <param name="portraitHeight">The height in the portrait mode.</param>
-        /// <param name="landscapeWidth">The width in the landscape mode.</param>
-        /// <param name="landscapeHeight">The height in the landscape mode.</param>
-        /// <exception cref="ArgumentException">This exception can be due to an invalid parameter.</exception>
-        /// <exception cref="UnauthorizedAccessException">This exception can be due to permission denied.</exception>
-        /// <exception cref="InvalidOperationException">The IME main loop has not started yet.</exception>
-        /// <since_tizen> 4 </since_tizen>
-        [Obsolete("Deprecated since API10. Will be removed in API12.")]
-        public static void SetSize(int portraitWidth, int portraitHeight, int landscapeWidth, int landscapeHeight)
-        {
-            ErrorCode error = ImeSetSize(portraitWidth, portraitHeight, landscapeWidth, landscapeHeight);
-            if (error != ErrorCode.None)
-            {
-                Log.Error(LogTag, "SetSize Failed with error " + error);
-                throw InputMethodExceptionFactory.CreateException(error);
-            }
-        }
-    }
-}
index 146c49b4efa94ba1abe71ac5cc42f60cac439e3f..124ee94d659fe26032aea153591ef4de1988f2ab 100644 (file)
@@ -1877,34 +1877,6 @@ namespace Tizen.Uix.InputMethod
             }
         }
 
-        /// <summary>
-        /// This API returns the input panel main window.
-        /// </summary>
-        /// <privilege>
-        /// http://tizen.org/privilege/ime
-        /// </privilege>
-        /// <returns>The input panel main window object on success, otherwise null.</returns>
-        /// <exception cref="UnauthorizedAccessException">This exception can be due to permission denied.</exception>
-        /// <exception cref="InvalidOperationException">
-        /// This can occur due to the following reasons:
-        /// 1) The IME main loop has not started yet.
-        /// 2) Operation failed.
-        /// </exception>
-        /// <since_tizen> 4 </since_tizen>
-        [Obsolete("Deprecated since API10. Will be removed in API12.")]
-        public static EditorWindow GetMainWindow()
-        {
-            EditorWindow._handle = ImeGetMainWindow();
-            EditorWindow obj = new EditorWindow();
-            ErrorCode error = (ErrorCode)Tizen.Internals.Errors.ErrorFacts.GetLastResult();
-            if (error != ErrorCode.None)
-            {
-                Log.Error(LogTag, "GetMainWindow Failed with error " + error);
-                throw InputMethodExceptionFactory.CreateException(error);
-            }
-            return obj;
-        }
-
         /// <summary>
         /// Sends the request to hide the IME.
         /// </summary>