gcn::AllegroInput Class Reference

#include <allegroinput.hpp>

Inheritance diagram for gcn::AllegroInput:

gcn::Input List of all members.

Detailed Description

Allegro implementation of the Input.

Definition at line 73 of file allegroinput.hpp.

Public Member Functions

 AllegroInput ()
 Constructor.
virtual ~AllegroInput ()
 Destructor.
virtual bool isKeyQueueEmpty ()
 Checks whether the key queue is empty or not.
virtual KeyInput dequeueKeyInput ()
 Dequeues the key input queue.
virtual bool isMouseQueueEmpty ()
 Checks whether the mouse queue is empyt or not.
virtual MouseInput dequeueMouseInput ()
 Dequeues the mouse input queue.
virtual void _pollInput ()
 Polls all exsisting input.

Protected Member Functions

virtual void pollMouseInput ()
 Handles the mouse input called by _pollInput.
virtual void pollKeyInput ()
 Handles the key input called by _pollInput.
virtual Key convertToKey (int scancode, int unicode)
 Converts scancode and unicode to Key object.

Protected Attributes

std::map< int, KeymPressedKeys
std::queue< KeyInputmKeyQueue
std::queue< MouseInputmMouseQueue
bool mMouseButton1
bool mMouseButton2
bool mMouseButton3
int mLastMouseX
int mLastMouseY
int mLastMouseZ


Member Function Documentation

void gcn::AllegroInput::_pollInput (  )  [virtual]

Polls all exsisting input.

It exists for Input implementation compatibility. It is used internally by the library.

Implements gcn::Input.

Definition at line 113 of file allegroinput.cpp.

References pollKeyInput(), and pollMouseInput().

KeyInput gcn::AllegroInput::dequeueKeyInput (  )  [virtual]

Dequeues the key input queue.

Returns:
key input.

Implements gcn::Input.

Definition at line 82 of file allegroinput.cpp.

References isKeyQueueEmpty(), and mKeyQueue.

MouseInput gcn::AllegroInput::dequeueMouseInput (  )  [virtual]

Dequeues the mouse input queue.

Returns:
mouse input.

Implements gcn::Input.

Definition at line 100 of file allegroinput.cpp.

References isMouseQueueEmpty(), and mMouseQueue.

bool gcn::AllegroInput::isKeyQueueEmpty (  )  [virtual]

Checks whether the key queue is empty or not.

Returns:
true if the key queue is empty.

Implements gcn::Input.

Definition at line 77 of file allegroinput.cpp.

References mKeyQueue.

Referenced by dequeueKeyInput().

bool gcn::AllegroInput::isMouseQueueEmpty (  )  [virtual]

Checks whether the mouse queue is empyt or not.

Returns:
true if the mouse queue is empty.

Implements gcn::Input.

Definition at line 95 of file allegroinput.cpp.

References mMouseQueue.

Referenced by dequeueMouseInput().


The documentation for this class was generated from the following files:
Generated on Sat Jul 29 19:38:48 2006 for Guichan by  doxygen 1.4.7