Add UP_DEVICE_KIND_COMPUTER as we'll need UP_DEVICE_KIND_TABLET for wacom tablets

This commit is contained in:
Richard Hughes 2010-06-01 14:25:10 +01:00
parent 6bb6602c06
commit 34add0cfe2
3 changed files with 5 additions and 1 deletions

View file

@ -79,6 +79,9 @@ up_device_kind_to_string (UpDeviceKind type_enum)
case UP_DEVICE_KIND_TABLET:
type = "tablet";
break;
case UP_DEVICE_KIND_COMPUTER:
type = "computer";
break;
default:
type = "unknown";
break;

View file

@ -47,6 +47,7 @@ typedef enum {
UP_DEVICE_KIND_PHONE,
UP_DEVICE_KIND_MEDIA_PLAYER,
UP_DEVICE_KIND_TABLET,
UP_DEVICE_KIND_COMPUTER,
UP_DEVICE_KIND_LAST
} UpDeviceKind;

View file

@ -126,7 +126,7 @@ up_device_idevice_coldplug (UpDevice *device)
model = g_udev_device_get_property (native, "ID_MODEL");
kind = UP_DEVICE_KIND_PHONE;
if (model != NULL && g_strstr_len (model, -1, "iPad")) {
kind = UP_DEVICE_KIND_TABLET;
kind = UP_DEVICE_KIND_COMPUTER;
} else if (model != NULL && g_strstr_len (model, -1, "iPod")) {
kind = UP_DEVICE_KIND_MEDIA_PLAYER;
}