Class KeyBindings


  • public class KeyBindings
    extends java.lang.Object
    Contains the key mappings and the actions. This should be persisted somehow in the future.
    • Field Detail

      • CTRL_L

        public static int CTRL_L
        CONTROL
      • SHIFT_L

        public static int SHIFT_L
        SHIFT
      • ALT_L

        public static int ALT_L
        ALT
    • Method Detail

      • initialize

        public static void initialize()
      • getMappingsInv

        public java.util.Map<KeyBindings.ProgramAction,​com.badlogic.gdx.utils.Array<java.util.TreeSet<java.lang.Integer>>> getMappingsInv()
      • getSortedMappings

        public java.util.Map<java.util.TreeSet<java.lang.Integer>,​KeyBindings.ProgramAction> getSortedMappings()
      • getSortedMappingsInv

        public java.util.Map<KeyBindings.ProgramAction,​com.badlogic.gdx.utils.Array<java.util.TreeSet<java.lang.Integer>>> getSortedMappingsInv()
      • findAction

        public KeyBindings.ProgramAction findAction​(java.lang.String name)
        Finds an action given its name
        Parameters:
        name - The name
        Returns:
        The action if it exists
      • getKeys

        public java.util.TreeSet<java.lang.Integer> getKeys​(java.lang.String actionId)
        Gets the keys that trigger the action identified by the given name
        Parameters:
        actionId - The action ID
        Returns:
        The keys
      • getStringKeys

        public java.lang.String getStringKeys​(java.lang.String actionId)