46 lines
1007 B
C++
46 lines
1007 B
C++
/* -----------------------------------------------------------------------------
|
|
GSFramework
|
|
Copyright 2001-2013 Emmanuel Julien. All Rights Reserved.
|
|
----------------------------------------------------------------------------- */
|
|
|
|
|
|
#ifndef __INPUT_NULL_DEVICE__
|
|
#define __INPUT_NULL_DEVICE__
|
|
|
|
|
|
#include "input/input_device.h"
|
|
|
|
|
|
namespace GS {
|
|
namespace Input {
|
|
|
|
/*
|
|
@short Null input device.
|
|
@author Emmanuel Julien (ejulien@nworks.fr)
|
|
*/
|
|
class NullDevice : public Device
|
|
{
|
|
public:
|
|
|
|
virtual Type GetType() const
|
|
{ return Type_Any; }
|
|
virtual const char *GetName() const
|
|
{ return "Null"; }
|
|
|
|
virtual void Update() {}
|
|
|
|
virtual bool IsDown(KeyCode) const { return false; }
|
|
virtual bool WasDown(KeyCode) const { return false; }
|
|
|
|
virtual bool GetInputRange(InputCode, float &min, float &max) const { return false; }
|
|
|
|
virtual float GetValue(InputCode) const { return 0; }
|
|
virtual float GetLastValue(InputCode) const { return 0; }
|
|
};
|
|
|
|
} // Input
|
|
} // GS
|
|
|
|
|
|
#endif // __INPUT_NULL_DEVICE__
|