Пример #1
0
 /// <summary>
 /// 
 /// </summary>
 /// <param name="profile"></param>
 /// <param name="category"></param>
 /// <param name="name"></param>
 /// <param name="keysAsText"></param>
 /// <param name="isGlobal"></param>
 private static void SetKeyboardShortcut(KeyboardShortcutProfile profile, String category, String name, String keysAsText, bool isGlobal = false)
 {
     KeyboardShortcut sc = GetKeyboardShortcut(profile, category, name);
     if (sc == null)
     {
         sc = new KeyboardShortcut();
         sc.Category = category;
         sc.Name = name;
         profile.Shortcuts.Add(sc);
     }
     SetKeyboardShortcut(sc, keysAsText, isGlobal);
 }
Пример #2
0
 /// <summary>
 /// 
 /// </summary>
 /// <param name="sc"></param>
 /// <param name="keysAsText"></param>
 /// <param name="isGlobal"></param>
 private static void SetKeyboardShortcut(KeyboardShortcut sc, String keysAsText, bool isGlobal = false)
 {
     sc.Keys = keysAsText;
     sc.IsGlobal = isGlobal;
 }