Exemplo n.º 1
0
        public Keymap getDefaultKeymap()
        {
            List <Keymap>  list     = this.getAllKeymaps();
            KeymapSettings settings = this.getKeymapSettings();

            foreach (Keymap keymap in list)
            {
                if (keymap.Filename == settings.getDefaultKeymap())
                {
                    return(keymap);
                }
            }
            return(null);
        }
Exemplo n.º 2
0
        public void setName(string name)
        {
            this.jsonObj.Remove("Title");
            this.jsonObj.Add("Title", name);

            //Needed to update the name in layout chooser because its names are stored in a different file
            KeymapSettings settings = new KeymapSettings(Settings.Default.keymaps_config);

            if (settings.isInLayoutChooser(this))
            {
                settings.removeFromLayoutChooser(this);
                settings.addToLayoutChooser(this);
            }

            save();
        }
Exemplo n.º 3
0
        public void setName(string name)
        {
            this.jsonObj.Remove("Title");
            this.jsonObj.Add("Title", name);

            //Needed to update the name in layout chooser because its names are stored in a different file
            KeymapSettings settings = new KeymapSettings(Settings.Default.keymaps_config);
            if(settings.isInLayoutChooser(this))
            {
                settings.removeFromLayoutChooser(this);
                settings.addToLayoutChooser(this);
            }

            save();
        }