Example #1
0
    void OnMouseUp()
    {
        isPressed = false;

        ButtonEventArgs eventArgs = new ButtonEventArgs();
        eventArgs.ButtonType = gameObject.name;

        ButtonMouseUp(this, eventArgs);
    }
Example #2
0
    void OnMouseDown()
    {
        isPressed = true;

        ButtonEventArgs eventArgs = new ButtonEventArgs();
        eventArgs.ButtonType = gameObject.name;

        ButtonMouseDown(this, eventArgs);
    }
Example #3
0
    void OnButtonMouseDown(object sender, ButtonEventArgs e)
    {
        ButtonBehav currentObj = sender as ButtonBehav;

        if (currentObj == spinButtonBehav) {
            SpinButtonDown(sender, EventArgs.Empty);
        } else {
            PushButtonDown(sender, EventArgs.Empty);
        }
    }