a bit more event work

git-svn-id: https://dolphin-emu.googlecode.com/svn/trunk@1719 8ced0084-cf51-0410-be5f-012b33b47a6e
This commit is contained in:
nakeee
2008-12-29 21:47:45 +00:00
parent a22d27bdc2
commit d75bcf9e63
4 changed files with 53 additions and 384 deletions

View File

@ -17,7 +17,7 @@ bool EventHandler::TestEvent (Keys k, sf::Event e)
}
// Taken from wxw source code
int wxCharCodeWXToX(int id)
int EventHandler::wxCharCodeWXToSF(int id)
{
int sfKey;

View File

@ -22,16 +22,16 @@ struct Keys
class EventHandler {
private:
listenFuncPtr keys[100][6];
listenFuncPtr mouse[6];
listenFuncPtr joys[10];
listenFuncPtr keys[sf::Key::Count][6];
listenFuncPtr mouse[sf::Mouse::Count];
listenFuncPtr joys[sf::Joy::Count];
std::queue<Keys> eventQueue;
public:
bool RegisterEventListener(listenFuncPtr func, int event, int type);
void Update();
bool addEvent(sf::Event *);
static bool TestEvent (Keys k, sf::Event e);
static int wxCharCodeWXToX(int id);
static int wxCharCodeWXToSF(int id);
static void SFKeyToString(unsigned int keycode, char *keyStr);
};