org.malai.interaction
Class ScrollTransition

java.lang.Object
  extended by org.malai.interaction.Transition
      extended by org.malai.interaction.PointingDeviceTransition
          extended by org.malai.interaction.ScrollTransition
All Implemented Interfaces:
ITransition
Direct Known Subclasses:
Scrolling.ScrollingScrollTransition

public class ScrollTransition
extends PointingDeviceTransition

This transition corresponds to a scroll event.

This file is part of Malai.
Copyright (c) 2009-2012 Arnaud BLOUIN

Malai is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.
Malai is distributed without any warranty; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

28/10/2010

Since:
0.2
Author:
Arnaud BLOUIN

Field Summary
protected  int amount
          The number of units to scroll by scroll.
protected  int direction
          Defines if the scrolling is up (positive value) or down (negative value).
protected  int type
          The type of scrolling that should take place in response to this event (block or unit increment).
 
Fields inherited from class org.malai.interaction.PointingDeviceTransition
button, source, x, y
 
Fields inherited from class org.malai.interaction.Transition
hid, inputState, outputState
 
Constructor Summary
ScrollTransition(SourceableState inputState, TargetableState outputState)
          Transition.Transition(SourceableState, TargetableState)
 
Method Summary
 int getAmount()
           
 int getDirection()
           
 int getType()
           
 void setAmount(int amount)
           
 void setDirection(int direction)
           
 void setType(int type)
           
 
Methods inherited from class org.malai.interaction.PointingDeviceTransition
getButton, getSource, getX, getY, setButton, setSource, setX, setY
 
Methods inherited from class org.malai.interaction.Transition
action, getHid, getInputState, getOutputState, isGuardRespected, setHid, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

direction

protected int direction
Defines if the scrolling is up (positive value) or down (negative value).


amount

protected int amount
The number of units to scroll by scroll.


type

protected int type
The type of scrolling that should take place in response to this event (block or unit increment).

Constructor Detail

ScrollTransition

public ScrollTransition(SourceableState inputState,
                        TargetableState outputState)
Transition.Transition(SourceableState, TargetableState)

Method Detail

getDirection

public int getDirection()
Returns:
The direction of the scrolling.
Since:
0.2

setDirection

public void setDirection(int direction)
Parameters:
direction - Defines if the scrolling is up (positive value) or down (negative value).
Since:
0.2

getAmount

public int getAmount()
Returns:
The number of units.
Since:
0.2

setAmount

public void setAmount(int amount)
Parameters:
amount - The number of units to scroll by scroll.
Since:
0.2

getType

public int getType()
Returns:
the type of scrolling.
Since:
0.2

setType

public void setType(int type)
Parameters:
type - The type of scrolling that should take place in response to this event (block or unit increment).
Since:
0.2