@@ -458,13 +458,7 @@ static void set_properties_from_evdev(struct udev_device *udev_device)
458458 udev_list_entry_add (& udev_device -> properties , "ID_INPUT_SWITCH" , "1" , 0 );
459459 }
460460
461- if (test_bit (ev_bits , EV_REL )) {
462- if (test_bit (rel_bits , REL_Y ) && test_bit (rel_bits , REL_X ) &&
463- test_bit (key_bits , BTN_MOUSE )) {
464- udev_list_entry_add (& udev_device -> properties , "ID_INPUT_MOUSE" , "1" , 0 );
465- }
466- }
467- else if (test_bit (ev_bits , EV_ABS )) {
461+ if (test_bit (ev_bits , EV_ABS )) {
468462 if (test_bit (key_bits , BTN_SELECT ) || test_bit (key_bits , BTN_TR ) ||
469463 test_bit (key_bits , BTN_START ) || test_bit (key_bits , BTN_TL )) {
470464 if (test_bit (key_bits , BTN_TOUCH )) {
@@ -494,6 +488,12 @@ static void set_properties_from_evdev(struct udev_device *udev_device)
494488 }
495489 }
496490 }
491+ else if (test_bit (ev_bits , EV_REL )) {
492+ if (test_bit (rel_bits , REL_Y ) && test_bit (rel_bits , REL_X ) &&
493+ test_bit (key_bits , BTN_MOUSE )) {
494+ udev_list_entry_add (& udev_device -> properties , "ID_INPUT_MOUSE" , "1" , 0 );
495+ }
496+ }
497497
498498 if (!test_bit (ev_bits , EV_KEY )) {
499499 return ;
0 commit comments