Java java.awt.event MouseWheelEvent fields, constructors, methods, implement or subclass

Example usage for Java java.awt.event MouseWheelEvent fields, constructors, methods, implement or subclass

Introduction

In this page you can find the methods, fields and constructors for java.awt.event MouseWheelEvent.

The text is from its open source code.

Field

intWHEEL_UNIT_SCROLL
Constant representing scrolling by "units" (like scrolling with the arrow keys)
intWHEEL_BLOCK_SCROLL
Constant representing scrolling by a "block" (like scrolling with page-up, page-down keys)

Constructor

MouseWheelEvent(Component source, int id, long when, int modifiers, int x, int y, int clickCount, boolean popupTrigger, int scrollType, int scrollAmount, int wheelRotation)
Constructs a MouseWheelEvent object with the specified source component, type, modifiers, coordinates, scroll type, scroll amount, and wheel rotation.

Method

voidconsume()
Consumes this event so that it will not be processed in the default manner by the source which originated it.
intgetButton()
Returns which, if any, of the mouse buttons has changed state.
intgetClickCount()
Returns the number of mouse clicks associated with this event.
ComponentgetComponent()
Returns the originator of the event.
intgetID()
Returns the event type.
intgetModifiers()
Returns the modifier mask for this event.
PointgetPoint()
Returns the x,y position of the event relative to the source component.
doublegetPreciseWheelRotation()
Returns the number of "clicks" the mouse wheel was rotated, as a double.
intgetScrollAmount()
Returns the number of units that should be scrolled per click of mouse wheel rotation.
intgetScrollType()
Returns the type of scrolling that should take place in response to this event.
intgetUnitsToScroll()
This is a convenience method to aid in the implementation of the common-case MouseWheelListener - to scroll a ScrollPane or JScrollPane by an amount which conforms to the platform settings.
intgetWheelRotation()
Returns the number of "clicks" the mouse wheel was rotated, as an integer.
longgetWhen()
Returns the difference in milliseconds between the timestamp of when this event occurred and midnight, January 1, 1970 UTC.
intgetX()
Returns the horizontal x position of the event relative to the source component.
intgetY()
Returns the vertical y position of the event relative to the source component.
booleanisConsumed()
Returns whether or not this event has been consumed.
booleanisControlDown()
Returns whether or not the Control modifier is down on this event.
booleanisMetaDown()
Returns whether or not the Meta modifier is down on this event.
booleanisPopupTrigger()
Returns whether or not this mouse event is the popup menu trigger event for the platform.
booleanisShiftDown()
Returns whether or not the Shift modifier is down on this event.
StringparamString()
Returns a parameter string identifying this event.