From 384b890f12b5e0a7a3e13c475ef33ae470edb5d1 Mon Sep 17 00:00:00 2001 From: John Toman Date: Thu, 20 Aug 2009 01:12:19 +0000 Subject: [PATCH] removes some code that shouldn't have been committed, fixes up a problem with rapid fire with buttons git-svn-id: svn://svn.code.sf.net/p/qjoypad/code/trunk@105 c05e91a0-76c8-4ec0-b377-ef19ce7cc080 --- src/button.cpp | 1 + src/joypad.cpp | 12 ------------ 2 files changed, 1 insertion(+), 12 deletions(-) diff --git a/src/button.cpp b/src/button.cpp index 1503400..438058f 100644 --- a/src/button.cpp +++ b/src/button.cpp @@ -94,6 +94,7 @@ void Button::jsevent( int value ) { } if (!isButtonPressed && rapidfire) { timer->stop(); + disconnect(timer, SIGNAL(timeout()), 0, 0); if(isDown) { click(false); } diff --git a/src/joypad.cpp b/src/joypad.cpp index 9d18038..d5f5e31 100644 --- a/src/joypad.cpp +++ b/src/joypad.cpp @@ -32,18 +32,6 @@ void JoyPad::resetToDev(int dev ) { ioctl (joydev, JSIOCGAXES, &axes); buttons = 0; ioctl (joydev, JSIOCGBUTTONS, &buttons); - //~ uint16_t *button_mapping = (uint16_t*)calloc(KEY_MAX - BTN_MISC + 1, 2); - //~ ioctl (joydev, JSIOCGBTNMAP, button_mapping); - //~ for(int i = 0; i < buttons; i++) { - //~ printf("%04X\n", button_mapping[i]); - //~ } - //~ free((void*)button_mapping); - //~ printf("axis mapping\n"); - //~ uint16_t *axis_mapping = (uint16_t*)calloc(ABS_MAX+1,2); - //~ for(int i = 0; i < ABS_MAX + 1; i++) { - //~ printf("%04X\n", axis_mapping[i]); - //~ } - //~ free((void*)axis_mapping); //make sure that we have the axes we need. //if one that we need doesn't yet exist, add it in. //Note: if the current layout has a key assigned to an axis that did not