Exemple #1
0
        public void ShowKeybindWarning(string warningMessage)
        {
            _keybindWarning = new TextBlockMessage("workspacer keybinds", "Warning, duplicate keybinds!", warningMessage, new List <Tuple <string, Action> >()
            {
                new Tuple <string, Action>("ok", () => { }),
            });

            _keybindWarning.Show();
        }
Exemple #2
0
        public void ShowKeybindDialog()
        {
            if (_keybindDialog == null)
            {
                var message = string.Join("\r\n", this.Keybinds.Select(k => (k.Item3 ?? "<unnamed>") + "  -  " + GetKeybindString(k.Item1, k.Item2)));
                _keybindDialog = new TextBlockMessage("workspacer keybinds", "below is the list of the current keybindings", message, new List <Tuple <string, Action> >()
                {
                    new Tuple <string, Action>("ok", () => { }),
                });
            }

            if (_keybindDialog.Visible)
            {
                _keybindDialog.Hide();
            }
            else
            {
                _keybindDialog.Show();
            }
        }