#include <msp/strings/format.h>
#include "device.h"
+using namespace std;
+
namespace Msp {
namespace Input {
Device::~Device()
{ }
+Device *Device::find_subdevice(const string &n)
+{
+ return (n==name ? this : 0);
+}
+
+Device *Device::find_subdevice(DeviceType t, unsigned i)
+{
+ return (t==type && i==0 ? this : 0);
+}
+
bool Device::get_button_state(unsigned btn) const
{
if(btn>=buttons.size())