$treeview $search $mathjax
Stratagus  2.2.6
$projectbrief
$projectbrief
$searchbox
-->
         _________ __                 __
        /   _____//  |_____________ _/  |______     ____  __ __  ______
        \_____  \\   __\_  __ \__  \\   __\__  \   / ___\|  |  \/  ___/
        /        \|  |  |  | \// __ \|  |  / __ \_/ /_/  >  |  /\___ \
       /_______  /|__|  |__|  (____  /__| (____  /\___  /|____//____  >
               \/                  \/          \//_____/            \/
    ______________________                           ______________________
                          T H E   W A R   B E G I N S
           Stratagus - A free fantasy real time strategy game engine

gcn::MouseInput Class Reference

#include <mouseinput.h>

List of all members.


Public Types

enum  {
  EMPTY = 0, LEFT, RIGHT, MIDDLE,
  WHEEL_UP, WHEEL_DOWN, PRESS, RELEASE,
  MOTION
}

Public Member Functions

 MouseInput ()
 MouseInput (int button, int type, int mousex, int mousey, int timeStamp)
void setType (int type)
int getType () const
void setButton (int button)
int getButton () const
void setTimeStamp (int timeStamp)
int getTimeStamp () const

Public Attributes

int x
int y

Protected Attributes

int mType
int mButton
int mTimeStamp

Detailed Description

Internal class representing mouse input. Generally you won't have to bother using this class.

Member Enumeration Documentation

anonymous enum

Enum with mouse input values.

Enumerator:
EMPTY 
LEFT 
RIGHT 
MIDDLE 
WHEEL_UP 
WHEEL_DOWN 
PRESS 
RELEASE 
MOTION 


Constructor & Destructor Documentation

gcn::MouseInput::MouseInput (  )  [inline]

Constructor.

gcn::MouseInput::MouseInput ( int  button,
int  type,
int  mousex,
int  mousey,
int  timeStamp 
)

Constructor.

Parameters:
button the button pressed.
type the type of input.
mousex the mouse x coordinate.
mousey the mouse y coordinate.
timeStamp the mouse inputs time stamp.


Member Function Documentation

void gcn::MouseInput::setType ( int  type  ) 

Sets the input type.

Parameters:
type the type of input.

int gcn::MouseInput::getType (  )  const

Gets the input type.

Returns:
the input type.

void gcn::MouseInput::setButton ( int  button  ) 

Sets the button pressed.

Parameters:
button the button pressed.

int gcn::MouseInput::getButton (  )  const

Gets the button pressed.

Returns:
the button pressed.

void gcn::MouseInput::setTimeStamp ( int  timeStamp  ) 

Sets the timestamp for the input.

Parameters:
timeStamp the timestamp of the input.

int gcn::MouseInput::getTimeStamp (  )  const

Gets the time stamp of the input.

Returns:
the time stamp of the input.


Member Data Documentation

int gcn::MouseInput::mType [protected]

int gcn::MouseInput::mButton [protected]

int gcn::MouseInput::mTimeStamp [protected]


The documentation for this class was generated from the following files:
(C) Copyright 1998-2011 by The Stratagus Project under the GNU General Public License.
All trademarks and copyrights on this page are owned by their respective owners.