コード例 #1
0
        /// <summary>
        /// Returns an instance of InputMethod from a specific Clsid.
        /// </summary>
        /// <param name="clsid">Class identifier of SIP class.</param>
        /// <returns></returns>
        public static InputMethod FromClsid(Guid clsid)
        {
            string name = "";

            //try and get a name for the SIP
            RegistryKey rksip = Registry.ClassesRoot.OpenSubKey("CLSID\\" + clsid.ToString("B"));

            if (rksip != null)
            {
                name = rksip.GetValue("").ToString();
                rksip.Close();
            }

            InputMethod im = new InputMethod(clsid, name);

            return(im);
        }
コード例 #2
0
		/// <summary>
		/// Returns an instance of InputMethod from a specific Clsid.
		/// </summary>
		/// <param name="clsid">Class identifier of SIP class.</param>
		/// <returns></returns>
		public static InputMethod FromClsid(Guid clsid)
		{
			string name = "";

			//try and get a name for the SIP
			RegistryKey rksip = Registry.ClassesRoot.OpenSubKey("CLSID\\" + clsid.ToString("B"));
			
			if(rksip != null)
			{
				name = rksip.GetValue("").ToString();
				rksip.Close();
			}

			InputMethod im = new InputMethod(clsid, name);

			return im;
		}
コード例 #3
0
			/// <summary>
			/// Determines the index of a specific item in the <see cref="InputMethodCollection"/> class.
			/// </summary>
			/// <param name="method">The input method to locate in the collection.</param>
			/// <returns>Index in the array.</returns>
			public int IndexOf(InputMethod method)
			{
				return methods.IndexOf(method);
			}
コード例 #4
0
			/// <summary>
			/// Determines whether the <see cref="InputMethodCollection"/> class contains a specified value.
			/// </summary>
			/// <param name="method">An <see cref="InputMethod"/> to locate in the collection.</param>
			/// <returns>true if present, else false.</returns>
			public bool Contains(InputMethod method)
			{
				return methods.Contains(method);
			}
コード例 #5
0
 /// <summary>
 /// Determines the index of a specific item in the <see cref="InputMethodCollection"/> class.
 /// </summary>
 /// <param name="method">The input method to locate in the collection.</param>
 /// <returns>Index in the array.</returns>
 public int IndexOf(InputMethod method)
 {
     return(methods.IndexOf(method));
 }
コード例 #6
0
 /// <summary>
 /// Determines whether the <see cref="InputMethodCollection"/> class contains a specified value.
 /// </summary>
 /// <param name="method">An <see cref="InputMethod"/> to locate in the collection.</param>
 /// <returns>true if present, else false.</returns>
 public bool Contains(InputMethod method)
 {
     return(methods.Contains(method));
 }