using UnityEngine.InputSystem.Utilities; namespace UnityEngine.InputSystem { /// /// A collection of common usage string values as reported by . /// public static class CommonUsages { /// /// Primary 2D motion control. /// /// /// Example: Left stick on a gamepad. /// public static readonly InternedString Primary2DMotion = new InternedString("Primary2DMotion"); /// /// Secondary 2D motion control. /// /// /// Example: Right stick on a gamepad. /// public static readonly InternedString Secondary2DMotion = new InternedString("Secondary2DMotion"); /// /// The primary action control on any input device, such as a gamepad, mouse, or keyboard. /// /// /// Example: Primary mouse button (left button on right-handed configuration, right button on left-handed configuration), /// south-button on a gamepad. /// public static readonly InternedString PrimaryAction = new InternedString("PrimaryAction"); /// /// Secondary action control on any input device, such as a gamepad, mouse, or keyboard. /// /// /// Example: Secondary mouse button (right button on right-handed configuration, left button on left-handed configuration), /// east-button on a gamepad. /// public static readonly InternedString SecondaryAction = new InternedString("SecondaryAction"); /// /// The primary trigger control on input devices with triggers. /// /// /// Example: Right trigger-button on a gamepad. /// public static readonly InternedString PrimaryTrigger = new InternedString("PrimaryTrigger"); /// /// The secondary trigger control on input devices with triggers. /// /// /// Example: Left trigger-button on a gamepad. /// public static readonly InternedString SecondaryTrigger = new InternedString("SecondaryTrigger"); /// /// A modifier action control that modifies usage of other controls. /// /// /// Example: Keyboard modifier keys like CTRL, SHIFT, ALT, OPTION, etc. /// public static readonly InternedString Modifier = new InternedString("Modifier"); /// /// The spatial position control on input devices with spatial tracking. /// /// /// Example: User head position in tracking-space using e.g. a head-tracking system. This could for example be a VR tracking system or another user-facing tracking sensor. /// public static readonly InternedString Position = new InternedString("Position"); /// /// The spatial orientation control on input devices with spatial tracking. /// /// /// Example: User head-orientation in tracking-space using e.g. a head-tracking system. This could for example be a VR tracking system or another user-facing tracking sensor. /// public static readonly InternedString Orientation = new InternedString("Orientation"); /// /// The primary hat-switch control on input devices with hat-switches such as joysticks or gamepads. /// /// /// Example: Joystick or gamepad hat-switch. /// public static readonly InternedString Hatswitch = new InternedString("Hatswitch"); /// /// Button to navigate to previous location. /// /// /// Example: Escape on keyboard, B button on gamepad. /// /// In general, the "Back" control is used for moving backwards in the navigation history /// of a UI. This is used, for example, in hierarchical menu structures to move back to parent menus /// (e.g. from the "Settings" menu back to the "Main" menu). Consoles generally have stringent requirements /// as to which button has to fulfill this role. /// public static readonly InternedString Back = new InternedString("Back"); /// /// Button to navigate to next location. /// public static readonly InternedString Forward = new InternedString("Forward"); /// /// Button to bring up menu. /// public static readonly InternedString Menu = new InternedString("Menu"); /// /// Button to confirm the current choice. /// public static readonly InternedString Submit = new InternedString("Submit"); ////REVIEW: isn't this the same as "Back"? /// /// Button to not accept the current choice. /// public static readonly InternedString Cancel = new InternedString("Cancel"); /// /// Horizontal motion axis. /// /// /// Example: X axis on mouse. /// public static readonly InternedString Horizontal = new InternedString("Horizontal"); /// /// Vertical motion axis. /// /// /// Example: Y axis on mouse. /// public static readonly InternedString Vertical = new InternedString("Vertical"); /// /// Rotation around single, fixed axis. /// /// /// Example: twist on joystick or twist of pen (few pens support that). /// public static readonly InternedString Twist = new InternedString("Twist"); /// /// Pressure level axis. /// /// /// Example: pen pressure. /// public static readonly InternedString Pressure = new InternedString("Pressure"); /// /// Axis to scroll horizontally. /// public static readonly InternedString ScrollHorizontal = new InternedString("ScrollHorizontal"); /// /// Axis to scroll vertically. /// public static readonly InternedString ScrollVertical = new InternedString("ScrollVertical"); /// /// A screen-space point. /// /// /// Example: Touch contact point. /// public static readonly InternedString Point = new InternedString("Point"); /// /// Low-frequency haptic motor for force-feedback. /// public static readonly InternedString LowFreqMotor = new InternedString("LowFreqMotor"); /// /// High-frequency haptic motor for force-feedback. /// public static readonly InternedString HighFreqMotor = new InternedString("HighFreqMotor"); /// /// Device in left hand. /// /// /// Example: left hand XR controller. /// public static readonly InternedString LeftHand = new InternedString("LeftHand"); /// /// Device in right hand. /// /// /// Example: right hand XR controller. /// public static readonly InternedString RightHand = new InternedString("RightHand"); /// /// Axis representing charge of battery (1=full, 0=empty). /// public static readonly InternedString BatteryStrength = new InternedString("BatteryStrength"); } }