class Opal::Input::Core::InputAction

Overview

Represents a single logical action (e.g., "move_up", "jump", "ui_accept") and its multi-slot bindings.

Defined in:

opal/input/core/remap_model.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(id : String, label : String | Nil = nil, category : String = "General", description : String = "", deadzone : Float32 = 0.2_f32, locked : Bool = false, max_slots : Int32 = 2, initial_bindings : Array(InputBinding | Nil) | Nil = nil) #

[View source]

Instance Method Detail

def active_bindings : Array(InputBinding) #

[View source]
def binding_at(slot : Int32) : InputBinding | Nil #

[View source]
def bindings : Array(InputBinding | Nil) #

[View source]
def category : String #

[View source]
def category=(category : String) #

[View source]
def clear_all : Bool #

[View source]
def clear_slot(slot : Int32) : Bool #

[View source]
def deadzone : Float32 #

[View source]
def deadzone=(deadzone : Float32) #

[View source]
def default_bindings : Array(InputBinding | Nil) #

[View source]
def description : String #

[View source]
def description=(description : String) #

[View source]
def id : String #

[View source]
def label : String #

[View source]
def label=(label : String) #

[View source]
def locked=(locked : Bool) #

[View source]
def locked? : Bool #

[View source]
def matches?(event : Terminal::KeyEvent) : Bool #

[View source]
def matches?(event : Terminal::MouseEvent) : Bool #

[View source]
def max_slots : Int32 #

[View source]
def modified? : Bool #

[View source]
def primary : InputBinding | Nil #

[View source]
def reset_to_defaults! : Bool #

[View source]
def search_text : String #

[View source]
def secondary : InputBinding | Nil #

[View source]
def set_binding(slot : Int32, binding : InputBinding | Nil, update_default : Bool = false) : Bool #

[View source]