____                _       __
    / __ )____  _____   | |     / /___ ___________
   / __  / __ \/ ___/   | | /| / / __ `/ ___/ ___/
  / /_/ / /_/ (__  )    | |/ |/ / /_/ / /  (__  )
 /_____/\____/____/     |__/|__/\__,_/_/  /____/

       A futuristic real-time strategy game.
          This file is part of Bos Wars.
(C) Copyright 2001-2007 by the Bos Wars and Stratagus Project. Distributed under the "GNU General Public License"

gcn::KeyInput Class Reference

#include <keyinput.h>

List of all members.

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.

Definition at line 67 of file keyinput.h.


Member Enumeration Documentation

anonymous enum

Enum with key input values.

Enumerator:
EMPTY 
PRESS 
RELEASE 

Definition at line 116 of file keyinput.h.


Constructor & Destructor Documentation

gcn::KeyInput::KeyInput (  )  [inline]

Constructor.

Definition at line 74 of file keyinput.h.

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

Constructor.

Parameters:
key the Key the input concerns.
type the type of input.

Definition at line 63 of file keyinput.cpp.

References mKey, and mType.


Member Function Documentation

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

Sets the input type.

Parameters:
type the type of input.

Definition at line 69 of file keyinput.cpp.

References mType.

Referenced by gcn::SDLInput::processKeyRepeat(), and gcn::SDLInput::pushInput().

int gcn::KeyInput::getType (  )  const

Gets the input type.

Returns:
the input type.

Definition at line 74 of file keyinput.cpp.

References mType.

Referenced by gcn::Widget::_keyInputMessage(), gcn::FocusHandler::checkHotKey(), and gcn::Gui::logic().

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

Sets the key the input concerns.

Parameters:
key the Key the input concerns.

Definition at line 79 of file keyinput.cpp.

References mKey.

Referenced by gcn::SDLInput::processKeyRepeat(), and gcn::SDLInput::pushInput().

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

Gets the key the input concerns.

Returns:
the Key the input concerns.

Definition at line 84 of file keyinput.cpp.

References mKey.

Referenced by gcn::Widget::_keyInputMessage(), gcn::FocusHandler::checkHotKey(), and gcn::Gui::logic().


Member Data Documentation

Key gcn::KeyInput::mKey [protected]

Definition at line 124 of file keyinput.h.

Referenced by getKey(), KeyInput(), and setKey().

int gcn::KeyInput::mType [protected]

Definition at line 125 of file keyinput.h.

Referenced by getType(), KeyInput(), and setType().

int gcn::KeyInput::mButton [protected]

Definition at line 126 of file keyinput.h.


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

Generated on Sat Feb 21 00:28:26 2009 for Bos Wars by  doxygen 1.5.6