yu.ac.bg.etf.javaqx.qswing.events
Class MouseWheelEvent

java.lang.Object
  extended byjava.util.EventObject
      extended byyu.ac.bg.etf.javaqx.qswing.events.QSwingEvent
          extended byyu.ac.bg.etf.javaqx.qswing.events.ComponentEvent
              extended byyu.ac.bg.etf.javaqx.qswing.events.InputEvent
                  extended byyu.ac.bg.etf.javaqx.qswing.events.MouseEvent
                      extended byyu.ac.bg.etf.javaqx.qswing.events.MouseWheelEvent
All Implemented Interfaces:
java.io.Serializable

public class MouseWheelEvent
extends MouseEvent

Mouse Wheel Event.

Version:
0.2.0
Author:
Slobodan Vrkacevic (slobodan.vrkacevic@gmail.com)
See Also:
Serialized Form

Field Summary
static int WHEEL_BLOCK_SCROLL
          Scrolling by blocks (pages).
static int WHEEL_UNIT_SCROLL
          Scrolling by units (lines).
 
Fields inherited from class yu.ac.bg.etf.javaqx.qswing.events.MouseEvent
BUTTON1, BUTTON2, BUTTON3, MOUSE_CLICKED, MOUSE_DRAGGED, MOUSE_ENTERED, MOUSE_EXITED, MOUSE_MOVED, MOUSE_PRESSED, MOUSE_RELEASED, MOUSE_WHEEL, NOBUTTON
 
Fields inherited from class yu.ac.bg.etf.javaqx.qswing.events.InputEvent
ALT_MASK, BUTTON1_MASK, BUTTON2_MASK, BUTTON3_MASK, CTRL_MASK, META_MASK, SHIFT_MASK
 
Fields inherited from class yu.ac.bg.etf.javaqx.qswing.events.ComponentEvent
COMPONENT_HIDDEN, COMPONENT_MOVED, COMPONENT_RESIZED, COMPONENT_SHOWN
 
Fields inherited from class yu.ac.bg.etf.javaqx.qswing.events.QSwingEvent
ACTION_EVENT_MASK, COMPONENT_EVENT_MASK, consumed, CONTEXT_MENU_EVENT_MASK, CUSTOM_CONTEXT_MENU_EVENT_MASK, FOCUS_EVENT_MASK, id, KEY_EVENT_MASK, LOCATION_TOOL_TIP_MASK, MOUSE_EVENT_MASK, MOUSE_MOTION_EVENT_MASK, MOUSE_WHEEL_EVENT_MASK, PAINT_EVENT_MASK, PAINT_VIEW_EVENT_MASK, WINDOW_EVENT_MASK
 
Fields inherited from class java.util.EventObject
source
 
Constructor Summary
MouseWheelEvent(JQComponent source, int id, long when, int modifiers, int x, int y, int clickCount, int scrollType, int scrollAmount, int wheelRotation)
          Constructs new MouseWheelEvent object.
 
Method Summary
 int getScrollAmount()
          Returns scroll amount.
 int getScrollType()
          Returns scroll type.
 int getUnitsToScroll()
          Returns the number of units to scroll.
 int getWheelRotation()
          Returns wheel rotation.
 java.lang.String paramString()
          Returns string representation of the event.
 
Methods inherited from class yu.ac.bg.etf.javaqx.qswing.events.MouseEvent
getButton, getClickCount, getPoint, getX, getY
 
Methods inherited from class yu.ac.bg.etf.javaqx.qswing.events.InputEvent
consume, getModifiers, getModifiersText, getWhen, isAltDown, isConsumed, isControlDown, isMetaDown, isShiftDown
 
Methods inherited from class yu.ac.bg.etf.javaqx.qswing.events.ComponentEvent
getComponent
 
Methods inherited from class yu.ac.bg.etf.javaqx.qswing.events.QSwingEvent
getID, toString
 
Methods inherited from class java.util.EventObject
getSource
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

WHEEL_UNIT_SCROLL

public static final int WHEEL_UNIT_SCROLL
Scrolling by units (lines).

See Also:
Constant Field Values

WHEEL_BLOCK_SCROLL

public static final int WHEEL_BLOCK_SCROLL
Scrolling by blocks (pages).

See Also:
Constant Field Values
Constructor Detail

MouseWheelEvent

public MouseWheelEvent(JQComponent source,
                       int id,
                       long when,
                       int modifiers,
                       int x,
                       int y,
                       int clickCount,
                       int scrollType,
                       int scrollAmount,
                       int wheelRotation)
Constructs new MouseWheelEvent object.

Parameters:
source - the source component
id - the event id
when - the time the event occurred
modifiers - the modifiers
x - the x coordinate of the mouse point
y - the y coordinate of the mouse point
clickCount - the click count
scrollType - the scroll type
scrollAmount - the scroll amount
wheelRotation - the wheel rotation
Throws:
java.lang.IllegalArgumentException - if the source is null
Method Detail

getScrollType

public int getScrollType()
Returns scroll type.

Returns:
scroll type

getScrollAmount

public int getScrollAmount()
Returns scroll amount.

Returns:
scroll amount

getWheelRotation

public int getWheelRotation()
Returns wheel rotation.

Returns:
wheel rotation

getUnitsToScroll

public int getUnitsToScroll()
Returns the number of units to scroll.

Returns:
the number of units to scroll

paramString

public java.lang.String paramString()
Returns string representation of the event.

Overrides:
paramString in class MouseEvent


Copyright © 2007 ETF and contributors. All Rights Reserved.