Main Page Namespace List Class Hierarchy Alphabetical List Compound List File List Namespace Members Compound Members File Members Related Pages

# Ogre::ScrollEvent Class Reference

`#include <OgreScrollEvent.h>`

Inheritance diagram for Ogre::ScrollEvent:

[legend]
List of all members.

## Public Types

enum | { SE_SCROLL_FIRST = 2001, SE_SCROLL_LAST = 2001 }
enum | { SE_SCROLL_PERFORMED = SE_SCROLL_FIRST }
| This event id indicates that a meaningful Scroll occured. More...
enum | { SHIFT_MASK = 1 << 0, CTRL_MASK = 1 << 1, META_MASK = 1 << 2, ALT_MASK = 1 << 3, BUTTON0_MASK = 1 << 4, BUTTON1_MASK = 1 << 5, BUTTON2_MASK = 1 << 6, BUTTON3_MASK = 1 << 7, BUTTON_ANY_MASK = 0xF << 4 }

## Public Methods

| ScrollEvent (ScrollTarget *source, int id, Real when, int modifiers, size_t topVisible, size_t range, size_t total)
| Constructs a ScrollEvent object with the specified source GuiElement,.
size_t | getTopVisible () const
size_t | getRange () const
size_t | getTotal () const
String | paramString () const
| Returns a parameter string identifying this Scroll event.
void | consume ()
| Consumes this event so that it will not be processed in the default manner by the source which originated it.
int | getModifiers () const
| Returns the modifiers flag for this event.
Real | getWhen () const
| Returns the timestamp of when this event occurred.
bool | isAltDown () const
| Returns whether or not the Alt modifier is down on this event.
bool | isConsumed () const
| Returns whether or not this event has been consumed.
bool | isControlDown () const
| Returns whether or not the Control modifier is down on this event.
bool | isMetaDown () const
| Returns whether or not the Meta modifier is down on this event.
bool | isShiftDown () const
| Returns whether or not the Shift modifier is down on this event.
bool | isEventBetween (int start, int end) const
int | getID () const
EventTarget * | getSource () const

## Protected Attributes

size_t | mTopVisible
| The nonlocalized string that gives more details.
size_t | mRange
size_t | mTotal
Real | mWhen
| Not implemented yet.
int | mModifiers
| The state of the modifier keys at the time the input event was fired.
EventTarget * | mSource
| The target to process the event.
int | mId
| The ID of the event.
bool | mConsumed
| whether the event has been consumed

## Member Enumeration Documentation

anonymous enum

Enumeration values:

  SE_SCROLL_FIRST | The first number in the range of ids used for Scroll events.
  SE_SCROLL_LAST | The last number in the range of ids used for Scroll events.

Definition at line 155 of file OgreScrollEvent.h.

anonymous enum

This event id indicates that a meaningful Scroll occured.

Enumeration values:

  SE_SCROLL_PERFORMED |

Definition at line 187 of file OgreScrollEvent.h.

anonymous enum`[inherited]`

Enumeration values:

  SHIFT_MASK | This flag indicates that the Shift key was down when the event occurred.
  CTRL_MASK | This flag indicates that the Control key was down when the event occurred.
  META_MASK | This flag indicates that the Meta key was down when the event occurred. For mouse events, this flag indicates that the right button was pressed or released.
  ALT_MASK | This flag indicates that the Alt key was down when the event occurred. For mouse events, this flag indicates that the middle mouse button was pressed or released.
  BUTTON0_MASK |
  BUTTON1_MASK |
  BUTTON2_MASK |
  BUTTON3_MASK |
  BUTTON_ANY_MASK |

Definition at line 93 of file OgreInputEvent.h.

## Constructor & Destructor Documentation

Ogre::ScrollEvent::ScrollEvent | ( | ScrollTarget * | source,
|  | int | id,
|  | Real | when,
|  | int | modifiers,
|  | size_t | topVisible,
|  | size_t | range,
|  | size_t | total
| ) |

Constructs a ScrollEvent object with the specified source GuiElement,.

type, modifiers, coordinates, and click count.

Parameters:

  source | the GuiElement that originated the event
  id | the integer that identifies the event
  when | a long int that gives the time the event occurred
  modifiers | the modifier keys down during event

(shift, ctrl, alt, meta)

Parameters:

  x | the horizontal x coordinate for the mouse location
  y | the vertical y coordinate for the mouse location
  ScrollCommand | The nonlocalized string that gives more details

of what actually caused the event.

Definition at line 36 of file OgreScrollEvent.cpp.

References Ogre::Real.

## Member Function Documentation

void Ogre::InputEvent::consume | ( |  | ) | `[inherited]`

| Consumes this event so that it will not be processed in the default manner by the source which originated it. Definition at line 43 of file OgreInputEvent.cpp. References Ogre::InputEvent::mConsumed. Referenced by Ogre::EventDispatcher::retargetMouseEvent().

int Ogre::InputEvent::getID | ( |  | ) | const`[inherited]`

Definition at line 89 of file OgreInputEvent.cpp.

References Ogre::InputEvent::mId.

Referenced by Ogre::ActionTarget::processActionEvent(), Ogre::TextBoxGuiElement::processEvent(), Ogre::ScrollBarGuiElement::processEvent(), Ogre::OverlayManager::processEvent(), Ogre::GuiElement::processEvent(), Ogre::GuiControl::processEvent(), Ogre::EventProcessor::processEvent(), Ogre::Cursor::processEvent(), Ogre::KeyTarget::processKeyEvent(), Ogre::MouseTarget::processMouseEvent(), Ogre::EventDispatcher::processMouseEvent(), Ogre::MouseMotionTarget::processMouseMotionEvent(), Ogre::ScrollTarget::processScrollEvent(), and Ogre::EventDispatcher::retargetMouseEvent().

int Ogre::InputEvent::getModifiers | ( |  | ) | const`[inherited]`

| Returns the modifiers flag for this event. Definition at line 48 of file OgreInputEvent.cpp. References Ogre::InputEvent::mModifiers. Referenced by Ogre::MouseEvent::paramString(), Ogre::EventDispatcher::retargetKeyEvent(), and Ogre::EventDispatcher::retargetMouseEvent().

size_t Ogre::ScrollEvent::getRange | ( |  | ) | const

| Definition at line 52 of file OgreScrollEvent.cpp. References mRange.

EventTarget * Ogre::InputEvent::getSource | ( |  | ) | const`[inherited]`

| Definition at line 95 of file OgreInputEvent.cpp. References Ogre::InputEvent::mSource. Referenced by Ogre::ScrollBarGuiElement::mousePressed(), and Ogre::ListGuiElement::mousePressed().

size_t Ogre::ScrollEvent::getTopVisible | ( |  | ) | const

| Definition at line 46 of file OgreScrollEvent.cpp. References mTopVisible. Referenced by Ogre::TTYGuiElement::scrollPerformed(), and Ogre::ListGuiElement::scrollPerformed().

size_t Ogre::ScrollEvent::getTotal | ( |  | ) | const

| Definition at line 59 of file OgreScrollEvent.cpp. References mTotal.

Real Ogre::InputEvent::getWhen | ( |  | ) | const`[inherited]`

| Returns the timestamp of when this event occurred. Not implemented yet Definition at line 53 of file OgreInputEvent.cpp. References Ogre::InputEvent::mWhen, and Ogre::Real. Referenced by Ogre::EventDispatcher::retargetKeyEvent(), and Ogre::EventDispatcher::retargetMouseEvent().

bool Ogre::InputEvent::isAltDown | ( |  | ) | const`[inherited]`

| Returns whether or not the Alt modifier is down on this event. Definition at line 58 of file OgreInputEvent.cpp. References Ogre::InputEvent::mModifiers.

bool Ogre::InputEvent::isConsumed | ( |  | ) | const`[inherited]`

Returns whether or not this event has been consumed.

See also:
  consume

Definition at line 63 of file OgreInputEvent.cpp.

References Ogre::InputEvent::mConsumed.

Referenced by Ogre::TextBoxGuiElement::processEvent(), Ogre::ScrollBarGuiElement::processEvent(), Ogre::GuiElement::processEvent(), Ogre::GuiControl::processEvent(), Ogre::EventProcessor::processEvent(), Ogre::EventDispatcher::processKeyEvent(), and Ogre::EventDispatcher::processMouseEvent().

bool Ogre::InputEvent::isControlDown | ( |  | ) | const`[inherited]`

| Returns whether or not the Control modifier is down on this event. Definition at line 68 of file OgreInputEvent.cpp. References Ogre::InputEvent::mModifiers.

bool Ogre::InputEvent::isEventBetween | ( | int | start,
|  | int | end
| ) | const`[inherited]`

| Definition at line 83 of file OgreInputEvent.cpp. References Ogre::InputEvent::mId. Referenced by Ogre::EventDispatcher::dispatchEvent().

bool Ogre::InputEvent::isMetaDown | ( |  | ) | const`[inherited]`

| Returns whether or not the Meta modifier is down on this event. Definition at line 73 of file OgreInputEvent.cpp. References Ogre::InputEvent::mModifiers.

bool Ogre::InputEvent::isShiftDown | ( |  | ) | const`[inherited]`

| Returns whether or not the Shift modifier is down on this event. Definition at line 78 of file OgreInputEvent.cpp. References Ogre::InputEvent::mModifiers.

String Ogre::ScrollEvent::paramString | ( |  | ) | const

Returns a parameter string identifying this Scroll event.

This method is useful for event-logging and for debugging.

Returns:
  a string identifying the event and its associated command

Definition at line 65 of file OgreScrollEvent.cpp.

References mRange, mTopVisible, mTotal, SE_SCROLL_PERFORMED, and Ogre::String.

## Member Data Documentation

bool Ogre::InputEvent::mConsumed`[protected, inherited]`

| whether the event has been consumed Definition at line 88 of file OgreInputEvent.h. Referenced by Ogre::InputEvent::consume(), Ogre::InputEvent::InputEvent(), and Ogre::InputEvent::isConsumed().

int Ogre::InputEvent::mId`[protected, inherited]`

| The ID of the event. Definition at line 83 of file OgreInputEvent.h. Referenced by Ogre::InputEvent::getID(), and Ogre::InputEvent::isEventBetween().

int Ogre::InputEvent::mModifiers`[protected, inherited]`

| The state of the modifier keys at the time the input event was fired. Definition at line 72 of file OgreInputEvent.h. Referenced by Ogre::KeyEvent::getKeyChar(), Ogre::InputEvent::getModifiers(), Ogre::InputEvent::isAltDown(), Ogre::InputEvent::isControlDown(), Ogre::InputEvent::isMetaDown(), and Ogre::InputEvent::isShiftDown().

size_t Ogre::ScrollEvent::mRange`[protected]`

| Definition at line 143 of file OgreScrollEvent.h. Referenced by getRange(), and paramString().

EventTarget* Ogre::InputEvent::mSource`[protected, inherited]`

| The target to process the event. This is ususally found by the dispatcher Definition at line 78 of file OgreInputEvent.h. Referenced by Ogre::InputEvent::getSource().

size_t Ogre::ScrollEvent::mTopVisible`[protected]`

| The nonlocalized string that gives more details. of what actually caused the event. This information is very specific to the component that fired it. Definition at line 141 of file OgreScrollEvent.h. Referenced by getTopVisible(), and paramString().

size_t Ogre::ScrollEvent::mTotal`[protected]`

| Definition at line 145 of file OgreScrollEvent.h. Referenced by getTotal(), and paramString().

Real Ogre::InputEvent::mWhen`[protected, inherited]`

| Not implemented yet. Definition at line 67 of file OgreInputEvent.h. Referenced by Ogre::InputEvent::getWhen().

The documentation for this class was generated from the following files:

- OgreScrollEvent.h
- OgreScrollEvent.cpp

Copyright © 2002-2003 by The OGRE Team
Last modified Sun Nov 28 19:51:36 2004