Afterglow.Input.InputDeviceBase.CheckReleasedButton C# (CSharp) Method

CheckReleasedButton() protected method

Checks whether the released button was pressed and was registered for an action and executes the action.
protected CheckReleasedButton ( Button button ) : void
button Button The button.
return void
        protected void CheckReleasedButton(Button button)
        {
            if (RegisteredButtons.ContainsKey(button))
            {
                var buttonAction = RegisteredButtons[button];
                if (buttonAction.State == ButtonState.WasReleased && buttonAction.WasDown)
                {
                    buttonAction.ExecuteAction();
                }
                buttonAction.WasDown = false;
            }
        }