private void ShortcutPresetClick(object sender, RoutedEventArgs e)
        {
            IShortcut shortcut;

            if ((shortcut = (e.OriginalSource as MenuItem)?.Tag as IShortcut) != null)
            {
                ShortcutAssistantLayerHandler layer = (ShortcutAssistantLayerHandler)this.DataContext;
                if (shortcut is ShortcutNode)
                {
                    layer.Properties._ShortcutKeys = ((ShortcutNode)shortcut).GetShortcuts();
                }
                else if (shortcut is ShortcutGroup)
                {
                    layer.Properties._ShortcutKeys = ((ShortcutGroup)shortcut).Shortcuts;
                }
                this.SetSettings();
                e.Handled = true;
            }
        }
 public Control_ShortcutAssistantLayer(ShortcutAssistantLayerHandler datacontext) : this()
 {
     this.DataContext = datacontext;
 }
        public Control_ShortcutAssistantLayer(ShortcutAssistantLayerHandler datacontext)
        {
            InitializeComponent();

            this.DataContext = datacontext;
        }