SHOW Signed
 

net.rim.device.api.system
Class EventInjector.NavigationEvent

java.lang.Object
  |
  +--net.rim.device.api.system.EventInjector.Event
        |
        +--net.rim.device.api.system.EventInjector.NavigationEvent
Enclosing class:
EventInjector

public static class EventInjector.NavigationEvent
extends EventInjector.Event

The event class that defines a Navigation event.

Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.

Since:
JDE 4.2.0
See Also:
EventInjector, EventInjector.Event, EventInjector.KeyCodeEvent, EventInjector.KeyEvent, EventInjector.TrackwheelEvent

Field Summary
 Category: Signed static int NAVIGATION_CLICK
          A constant representing a navigation click.
 Category: Signed static int NAVIGATION_MOVEMENT
          A constant representing a navigation movement.
 Category: Signed static int NAVIGATION_UNCLICK
          A constant representing a navigation click released.
   
Constructor Summary
 Category: Signed EventInjector.NavigationEvent(int event, int dx, int dy, int status)
          Constructs a new NavigationEvent instance whose time is set to the current device uptime.
 
Method Summary
 Category: Signed  int getAmountX()
          Returns the amount to move left/right before the event will occur.
 Category: Signed  int getAmountY()
          Returns the amount to move up/down before the event will occur.
 Category: Signed  int getStatus()
          Returns the status.
 Category: Signed  void setAmount(int dx, int dy)
          Sets the amount to move for the event to occur.
 
Methods inherited from class net.rim.device.api.system.EventInjector.Event
getEvent, getTime, post, setEvent, setStatus, setTimeToCurrent
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

NAVIGATION_CLICK

public static final int NAVIGATION_CLICK
A constant representing a navigation click.
Since:
JDE 4.2.0
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.

NAVIGATION_MOVEMENT

public static final int NAVIGATION_MOVEMENT
A constant representing a navigation movement.
Since:
JDE 4.2.0
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.

NAVIGATION_UNCLICK

public static final int NAVIGATION_UNCLICK
A constant representing a navigation click released.
Since:
JDE 4.2.0
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Constructor Detail

EventInjector.NavigationEvent

public EventInjector.NavigationEvent(int event,
                                     int dx,
                                     int dy,
                                     int status)
Constructs a new NavigationEvent instance whose time is set to the current device uptime.

Parameters:
event - One of NAVIGATION_CLICK, NAVIGATION_UNCLICK, NAVIGATION_MOVEMENT.
dx - The amount by which to move left/right, positive is right, negative is left. If dx is smaller than -32767 or greater than 32727 unexpected results may occur.
dy - The amount by which to move up/down, positive is down, negative is up. If dy is smaller than -32767 or greater than 32727 unexpected results may occur.
status - Any status flags (as defined by KeypadListener).
Throws:
IllegalArgumentException - If the values for dx or dy are invalid.
Since:
JDE 4.2.0
See Also:
Characters
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.
Method Detail

getAmountX

public int getAmountX()
Returns the amount to move left/right before the event will occur.

Returns:
The magnitude to move left/right.
Since:
JDE 4.2.0
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.

getAmountY

public int getAmountY()
Returns the amount to move up/down before the event will occur.

Returns:
The magnitude to move up/down.
Since:
JDE 4.2.0
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.

getStatus

public int getStatus()
Returns the status.

Overrides:
getStatus in class EventInjector.Event
Returns:
An integer representing the status.
Since:
JDE 4.2.1
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.

setAmount

public void setAmount(int dx,
                      int dy)
Sets the amount to move for the event to occur.

Parameters:
dx - The amount by which to move left/right, positive is right, negative is left. If dx is smaller than -32767 or greater than 32727 unexpected results may occur.
dy - The amount by which to move up/down, positive is down, negative is up. If dy is smaller than -32767 or greater than 32727 unexpected results may occur.
Since:
JDE 4.2.0
Category:
Signed: This element is only accessible by signed applications. If you intend to use this element, please visit http://www.blackberry.com/go/codesigning to obtain a set of code signing keys. Code signing is only required for applications running on BlackBerry smartphones; development on BlackBerry Smartphone Simulators can occur without code signing.



Copyright 1999-2009 Research In Motion Limited. 295 Phillip Street, Waterloo, Ontario, Canada, N2L 3W8. All Rights Reserved.
Copyright 1993-2003 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A.
Copyright 2002-2003 Nokia Corporation All Rights Reserved.
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.