类 InputEvent.MouseScrollingEvent

java.lang.Object
net.minecraftforge.eventbus.api.Event
net.minecraftforge.client.event.InputEvent
net.minecraftforge.client.event.InputEvent.MouseScrollingEvent
封闭类:
InputEvent

public static class InputEvent.MouseScrollingEvent extends InputEvent
Fired when a mouse scroll wheel is used outside of a screen and a player is loaded, before being processed by vanilla.

This event is cancellable, and does not have a result. If the event is cancelled, then the mouse scroll event will not be processed further.

This event is fired on the main Forge event bus, only on the logical client.

另请参阅:
  • 嵌套类概要

    从类继承的嵌套类/接口 net.minecraftforge.eventbus.api.Event

    net.minecraftforge.eventbus.api.Event.HasResult, net.minecraftforge.eventbus.api.Event.Result
  • 字段概要

    字段
    修饰符和类型
    字段
    说明
    private final double
     
    private final double
     
    private final boolean
     
    private final boolean
     
    private final double
     
    private final double
     
    private final boolean
     
  • 构造器概要

    构造器
    构造器
    说明
    MouseScrollingEvent(double deltaX, double deltaY, boolean leftDown, boolean middleDown, boolean rightDown, double mouseX, double mouseY)
     
  • 方法概要

    修饰符和类型
    方法
    说明
    double
    返回 the amount of change / delta of the mouse scroll in the vertical direction。
    double
    返回 the amount of change / delta of the mouse scroll in the horizontal direction。
    double
    返回 the X position of the mouse cursor。
    double
    返回 the Y position of the mouse cursor。
    boolean
    返回 true if the left mouse button is pressed。
    boolean
    返回 true if the middle mouse button is pressed。
    boolean
    返回 true if the right mouse button is pressed。

    从类继承的方法 net.minecraftforge.eventbus.api.Event

    getListenerList, getPhase, getResult, hasResult, isCancelable, isCanceled, setCanceled, setPhase, setResult

    从类继承的方法 java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 字段详细资料

    • deltaX

      private final double deltaX
    • deltaY

      private final double deltaY
    • mouseX

      private final double mouseX
    • mouseY

      private final double mouseY
    • leftDown

      private final boolean leftDown
    • middleDown

      private final boolean middleDown
    • rightDown

      private final boolean rightDown
  • 构造器详细资料

    • MouseScrollingEvent

      @Internal public MouseScrollingEvent(double deltaX, double deltaY, boolean leftDown, boolean middleDown, boolean rightDown, double mouseX, double mouseY)
  • 方法详细资料

    • getDeltaX

      public double getDeltaX()
      返回 the amount of change / delta of the mouse scroll in the vertical direction。
      返回:
      the amount of change / delta of the mouse scroll in the vertical direction
    • getDeltaY

      public double getDeltaY()
      返回 the amount of change / delta of the mouse scroll in the horizontal direction。
      返回:
      the amount of change / delta of the mouse scroll in the horizontal direction
    • isLeftDown

      public boolean isLeftDown()
      返回 true if the left mouse button is pressed。
      返回:
      true if the left mouse button is pressed
    • isRightDown

      public boolean isRightDown()
      返回 true if the right mouse button is pressed。
      返回:
      true if the right mouse button is pressed
    • isMiddleDown

      public boolean isMiddleDown()
      返回 true if the middle mouse button is pressed。
      返回:
      true if the middle mouse button is pressed
    • getMouseX

      public double getMouseX()
      返回 the X position of the mouse cursor。
      返回:
      the X position of the mouse cursor
    • getMouseY

      public double getMouseY()
      返回 the Y position of the mouse cursor。
      返回:
      the Y position of the mouse cursor