Home | Namespaces | Hierarchy | Alphabetical List | Class list | Files | Namespace Members | Class members | File members
E:/Programming/MyProject/K_Game_hg/GameEngine/include/input/Keyboard.h
Go to the documentation of this file.
00001 // Copyright 2006-2011 by Kat'Oun
00002 
00003 #ifndef _KEYBOARD_H_
00004 #define _KEYBOARD_H_
00005 
00006 #include <EngineConfig.h>
00007 #include <core/Types.h>
00008 #include <input/InputDevice.h>
00009 
00010 #include <list>
00011 
00012 namespace input
00013 {
00014 
00015 class KeyEventReceiver;
00016 class KeyEvent;
00017 enum KeyCode;
00018 enum KeyModifier;
00019 
00021 class ENGINE_PUBLIC_EXPORT Keyboard : public InputDevice
00022 {
00023 public:
00024 
00026         Keyboard();
00027 
00029         virtual ~Keyboard();
00030 
00032         virtual bool isKeyDown(KeyCode key) = 0;
00033 
00035         bool isModifierDown(KeyModifier modifier);
00036 
00037         void addKeyEventReceiver(input::KeyEventReceiver* newEventReceiver);
00038         void removeKeyEventReceiver(input::KeyEventReceiver* oldEventReceiver);
00039 
00040 protected:
00041 
00042         void initProperties();
00043 
00045         std::list<input::KeyEventReceiver*> mKeyEventReceivers;
00046 
00047         KeyEvent* mEvent;
00048 
00050         u32 mModifiers;
00051 };
00052 
00053 } // end namespace input
00054 
00055 #endif

The KG Game Engine
The KG Game Engine Documentation © 2006-2011 by Kat'Oun. Generated on Sat Jul 2 2011 00:50:04 by Doxygen (1.7.4)