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

Public Types | Public Member Functions | Protected Attributes | List of all members
gcn::KeyInput Class Reference

#include <keyinput.h>

Public Types

enum  { EMPTY = 0, PRESS, RELEASE }
 

Public Member Functions

 KeyInput ()
 
 KeyInput (const Key &key, int type)
 
void setType (int type)
 
int getType () const
 
void setKey (const Key &key)
 
const KeygetKey () const
 

Protected Attributes

Key mKey
 
int mType
 
int mButton
 

Detailed Description

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

Member Enumeration Documentation

◆ anonymous enum

anonymous enum

Enum with key input values.

Enumerator
EMPTY 
PRESS 
RELEASE 

Constructor & Destructor Documentation

◆ KeyInput() [1/2]

gcn::KeyInput::KeyInput ( )
inline

Constructor.

◆ KeyInput() [2/2]

gcn::KeyInput::KeyInput ( const Key key,
int  type 
)

Constructor.

Parameters
keythe Key the input concerns.
typethe type of input.

Member Function Documentation

◆ getKey()

const Key & gcn::KeyInput::getKey ( ) const

Gets the key the input concerns.

Returns
the Key the input concerns.

◆ getType()

int gcn::KeyInput::getType ( ) const

Gets the input type.

Returns
the input type.

◆ setKey()

void gcn::KeyInput::setKey ( const Key key)

Sets the key the input concerns.

Parameters
keythe Key the input concerns.

◆ setType()

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

Sets the input type.

Parameters
typethe type of input.

Member Data Documentation

◆ mButton

int gcn::KeyInput::mButton
protected

◆ mKey

Key gcn::KeyInput::mKey
protected

◆ mType

int gcn::KeyInput::mType
protected

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