input mouse mm: Trace event, status and positional information
Change-Id: I5689355c15139d7a194ecb74a9206718afee9b2b
Reviewed-on: https://review.haiku-os.org/c/haiku/+/9914
Tested-by: Commit checker robot <no-reply+buildbot@haiku-os.org>
Reviewed-by: Adrien Destugues <pulkomandy@pulkomandy.tk>
Diff
src/add-ons/input_server/devices/mouse/movement_maker.cpp | 29 +++++++++++++++++++++++++++++
src/add-ons/input_server/devices/mouse/movement_maker.h | 2 ++
2 files changed, 31 insertions(+)
@@ -23,6 +23,7 @@
#include <stdlib.h>
#include <math.h>
#include <private/utils/BitUtils.h>
@@ -267,6 +268,34 @@
if (!movement)
return B_ERROR;
TRACE("TM_EVENT: b:0x%" B_PRIx8 " nf:%" B_PRId8 " f:0x%" B_PRIx8
" x:%" B_PRIu32 " y:%" B_PRIu32 " p:%" B_PRIu8 " w:%" B_PRIu8 "\n",
event->buttons,
count_set_bits(event->fingers),
event->fingers,
event->xPosition,
event->yPosition,
event->zPressure,
event->fingerWidth
);
TRACE("TM_STATUS: b:0x%" B_PRIx8 " %c%c%c%c%c%c"
" dx:%" B_PRId32 " dy:%" B_PRId32
" tcks:%" B_PRId32 " cks:%" B_PRId32 "\n",
fButtonsState,
fMovementStarted ? 'M' : 'm',
fScrollingStarted ? 'S' : 's',
fTapStarted ? 'T' : 't',
fTapdragStarted ? 'D' : 'd',
fValidEdgeMotion ? 'E' : 'e',
fDoubleClick ? 'C' : 'c',
fTapDeltaX,
fTapDeltaY,
fTapClicks,
fClickCount
);
movement->xdelta = 0;
movement->ydelta = 0;
@@ -42,8 +42,10 @@
bool fMovementMakerStarted;
private:
uint32 fPreviousX;
uint32 fPreviousY;
float fDeltaSumX;
float fDeltaSumY;