예제 #1
0
        public Control_ToggleKeyLayer(ToggleKeyLayerHandler context)
        {
            InitializeComponent();
            DataContext = context;

            triggerKeyList.Keybinds = context.Properties._TriggerKeys;
        }
        public void SetSettings()
        {
            if (DataContext is ToggleKeyLayerHandler && !settingsset)
            {
                ToggleKeyLayerHandler context = (ToggleKeyLayerHandler)DataContext;

                defaultColor.SelectedColor = Utils.ColorUtils.DrawingColorToMediaColor(context.Properties._PrimaryColor ?? System.Drawing.Color.Empty);
                toggleColor.SelectedColor  = Utils.ColorUtils.DrawingColorToMediaColor(context.Properties._SecondaryColor ?? System.Drawing.Color.Empty);
                triggerKeyList.Keybinds    = context.Properties._TriggerKeys;
                KeySequence_Keys.Sequence  = context.Properties._Sequence;

                settingsset = true;
            }
        }
 public Control_ToggleKeyLayer(ToggleKeyLayerHandler context)
 {
     InitializeComponent();
     this.DataContext = context;
 }