mirror of
https://github.com/jpd002/Play-.git
synced 2025-04-28 13:47:57 +03:00
22 lines
484 B
C++
22 lines
484 B
C++
#pragma once
|
|
|
|
#include "PadInterface.h"
|
|
#include <list>
|
|
#include <functional>
|
|
|
|
class CPadHandler
|
|
{
|
|
public:
|
|
typedef std::function<CPadHandler*(void)> FactoryFunction;
|
|
|
|
CPadHandler() = default;
|
|
virtual ~CPadHandler() = default;
|
|
virtual void Update(uint8*) = 0;
|
|
void InsertListener(CPadInterface*);
|
|
bool HasListener(CPadInterface*) const;
|
|
void RemoveAllListeners();
|
|
|
|
protected:
|
|
typedef std::list<CPadInterface*> ListenerList;
|
|
ListenerList m_interfaces;
|
|
};
|