#ifndef __SMKEYBOARD

#define __SMKEYBOARD

#include "SM_Main.h"

class CKeyboardHandler : public SM_Main::IKeyboard
{
public:
  CKeyboardHandler                ();
  ~CKeyboardHandler               ();

  int Init                        ();
  int Shutdown                    ();

  virtual void  OnKeyDown         (int iVirtKey, bool bAlt);
  virtual void  OnKeyUp           (int iVirtKey, bool bAlt);

  int           IsDown            (int iVirtKey);
  int           IsPressed         (int iVirtKey);

  int           Reset             ();  
protected:  
  struct TKeyState
  {
    bool      m_bActualyPressed;
    unsigned  m_uTimesPressed;
  };

  TKeyState                     m_KeyStates[256];  
};

#endif