using System; using System.Collections.Generic; using Annulus; using Azimuth; using Glass; namespace Clave.Glass { /// /// One chord of an action, shown as its keys with a button at the end that takes it out. Activating it captures /// the next keys pressed in its place, and a Shift, Ctrl or Alt in it is a button that steps through which side /// counts. /// public class KeyBindingSlot : Button { /// /// The keys that take a focused slot's chord out. /// public static readonly ChordSet RemoveChords = ChordSet.Of(Chord.OnPressOrRepeat(KeyCode.Delete), Chord.OnPressOrRepeat(KeyCode.Backspace)); private readonly KeyBindingsEditor editor; private readonly KeyBindings source; private readonly KeyAction action; private readonly KeyBindingsMaterial material; private readonly List parts = new List(); private readonly List partSizes = new List(); // The label of each key, which is inside its button when the key has sides. private readonly List