--- a/src/Graphics/Input.cc Thu Jan 22 00:13:53 2009 +0200
+++ b/src/Graphics/Input.cc Thu Jan 22 00:28:26 2009 +0200
@@ -151,7 +151,7 @@
return;
// all bits that are held down, even those ignored
- BitMaskType raw_value = 0;
+ BitMaskType raw_value = 0, this_value = 0;
// update the key-repeat queue
queue.update(dt);
@@ -187,15 +187,23 @@
}
}
- // set bit in masks
- this->value |= e->input;
+ // set bit in value mask
+ this_value |= e->input;
}
}
+ // signal unless value was and remains zero
+ if (this_value || prev_value) {
+ // trigger signal
+ _sig_input(this_value, dt);
+ }
+
// update prev_value, also adding ignored values
prev_value = raw_value;
- // then increment our dt
+ // update our collective value + dt for use with readValue
+ // XXX: remove this functionality?
+ value |= this_value;
this->dt += dt;
}