Lines Matching refs:buttons
391 mm->buttons = ((data[0] & 0x20) ? kPrimaryButton : 0) +
398 // up to here we've handled "ye olde" 2-buttons MS packet.
399 // There's a 3-buttons extension to it, consisting in sending a
400 // "null packet" (no changes in x/y nor in standard buttons)
404 ((uint8) mm->buttons == (previous_buttons & ~kTertiaryButton))) {
406 mm->buttons = previous_buttons ^ kTertiaryButton;
409 mm->buttons |= previous_buttons & kTertiaryButton;
412 previous_buttons = mm->buttons;
416 // TODO: add support for 4th and 5th buttons?
417 mm->buttons = ((data[0] & 0x20) ? kPrimaryButton : 0) +
436 mm->buttons = ((tmp & 0x4) ? kPrimaryButton : 0) +
449 mm->buttons = ((data[0] & 0x20) ? kPrimaryButton : 0) +
475 if (mm->buttons ^ fButtonsState)
476 LOG(("Buttons = %ld\n", mm->buttons));