OIS::Win32InputManager Class Reference

#include <Win32InputManager.h>

Inheritance diagram for OIS::Win32InputManager:
[legend]
Collaboration diagram for OIS::Win32InputManager:
[legend]

List of all members.

Public Member Functions

 Win32InputManager ()
virtual ~Win32InputManager ()
virtual const std::string & inputSystemName ()
virtual int numJoysticks ()
virtual int numMice ()
virtual int numKeyBoards ()
ObjectcreateInputObject (Type iType, bool bufferMode)
void destroyInputObject (Object *obj)
HWND getWindowHandle ()
 Returns HWND needed by DirectInput Device Object.
void _initialize (ParamList &paramList)

Protected Member Functions

void _parseConfigSettings (ParamList &paramList)
 internal class method for dealing with param list
void _enumerateDevices ()
 internal class method for finding attached devices

Static Protected Member Functions

static BOOL CALLBACK _DIEnumKbdCallback (LPCDIDEVICEINSTANCE lpddi, LPVOID pvRef)

Protected Attributes

JoyStickInfoList unusedJoyStickList
HWND hWnd
IDirectInput8 * mDirectInput
DWORD kbSettings
DWORD mouseSettings
DWORD joySettings
char joySticks

Static Protected Attributes

static const std::string iName = "Win32"


Detailed Description

"Win32" InputManager specialization - Using DirectInput8

Definition at line 34 of file Win32InputManager.h.


Constructor & Destructor Documentation

Win32InputManager::Win32InputManager (  ) 

Definition at line 34 of file Win32InputManager.cpp.

References hWnd, joySettings, joySticks, kbSettings, mDirectInput, and mouseSettings.

Win32InputManager::~Win32InputManager (  )  [virtual]

Definition at line 47 of file Win32InputManager.cpp.

References mDirectInput.


Member Function Documentation

virtual const std::string& OIS::Win32InputManager::inputSystemName (  )  [inline, virtual]

Remarks:
Gets the name of the current input system.. eg. "Win32", "Linux", "XBox", etc

Implements OIS::InputManager.

Definition at line 41 of file Win32InputManager.h.

References iName.

int Win32InputManager::numJoysticks (  )  [virtual]

Remarks:
Returns the number of joysticks found

Implements OIS::InputManager.

Definition at line 143 of file Win32InputManager.cpp.

References joySticks.

int Win32InputManager::numMice (  )  [virtual]

Remarks:
Returns the number of mice found

Implements OIS::InputManager.

Definition at line 149 of file Win32InputManager.cpp.

int Win32InputManager::numKeyBoards (  )  [virtual]

Remarks:
Returns the number of keyboards found

Implements OIS::InputManager.

Definition at line 155 of file Win32InputManager.cpp.

Object * Win32InputManager::createInputObject ( Type  iType,
bool  bufferMode 
) [virtual]

Remarks:
Returns the type of input requested or raises Exception

Implements OIS::InputManager.

Definition at line 161 of file Win32InputManager.cpp.

References OIS::Object::_initialize(), E_InputDeviceNonExistant, E_InputDeviceNotSupported, joySettings, kbSettings, mDirectInput, mouseSettings, OIS_EXCEPT, OISJoyStick, OISKeyboard, OISMouse, and unusedJoyStickList.

void Win32InputManager::destroyInputObject ( Object obj  )  [virtual]

Remarks:
Destroys Input Object

Implements OIS::InputManager.

Definition at line 196 of file Win32InputManager.cpp.

References OISJoyStick, OIS::Object::type(), and unusedJoyStickList.

HWND OIS::Win32InputManager::getWindowHandle (  )  [inline]

Returns HWND needed by DirectInput Device Object.

Definition at line 56 of file Win32InputManager.h.

References hWnd.

void Win32InputManager::_initialize ( ParamList paramList  )  [virtual]

Internal... Called from createInputSystem.

Implements OIS::InputManager.

Definition at line 57 of file Win32InputManager.cpp.

References _enumerateDevices(), _parseConfigSettings(), DIRECTINPUT_VERSION, E_InvalidParam, hWnd, mDirectInput, and OIS_EXCEPT.

void Win32InputManager::_parseConfigSettings ( ParamList paramList  )  [protected]

internal class method for dealing with param list

Definition at line 86 of file Win32InputManager.cpp.

References joySettings, kbSettings, and mouseSettings.

Referenced by _initialize().

void Win32InputManager::_enumerateDevices (  )  [protected]

internal class method for finding attached devices

Definition at line 113 of file Win32InputManager.cpp.

References _DIEnumKbdCallback(), and mDirectInput.

Referenced by _initialize().

BOOL CALLBACK Win32InputManager::_DIEnumKbdCallback ( LPCDIDEVICEINSTANCE  lpddi,
LPVOID  pvRef 
) [static, protected]

Definition at line 120 of file Win32InputManager.cpp.

References OIS::JoyStickInfo::deviceID, OIS::JoyStickInfo::devId, joySticks, unusedJoyStickList, and OIS::JoyStickInfo::vendor.

Referenced by _enumerateDevices().


Member Data Documentation

JoyStickInfoList OIS::Win32InputManager::unusedJoyStickList [protected]

Definition at line 68 of file Win32InputManager.h.

Referenced by _DIEnumKbdCallback(), createInputObject(), and destroyInputObject().

const std::string Win32InputManager::iName = "Win32" [static, protected]

Definition at line 70 of file Win32InputManager.h.

Referenced by inputSystemName().

HWND OIS::Win32InputManager::hWnd [protected]

Definition at line 71 of file Win32InputManager.h.

Referenced by _initialize(), getWindowHandle(), and Win32InputManager().

IDirectInput8* OIS::Win32InputManager::mDirectInput [protected]

Definition at line 74 of file Win32InputManager.h.

Referenced by _enumerateDevices(), _initialize(), createInputObject(), Win32InputManager(), and ~Win32InputManager().

DWORD OIS::Win32InputManager::kbSettings [protected]

Definition at line 77 of file Win32InputManager.h.

Referenced by _parseConfigSettings(), createInputObject(), and Win32InputManager().

DWORD OIS::Win32InputManager::mouseSettings [protected]

Definition at line 78 of file Win32InputManager.h.

Referenced by _parseConfigSettings(), createInputObject(), and Win32InputManager().

DWORD OIS::Win32InputManager::joySettings [protected]

Definition at line 79 of file Win32InputManager.h.

Referenced by _parseConfigSettings(), createInputObject(), and Win32InputManager().

char OIS::Win32InputManager::joySticks [protected]

Definition at line 81 of file Win32InputManager.h.

Referenced by _DIEnumKbdCallback(), numJoysticks(), and Win32InputManager().


The documentation for this class was generated from the following files:
Generated on Sat Dec 1 20:13:55 2007 for OIS by  doxygen 1.5.4