summaryrefslogtreecommitdiff
path: root/plugins/wacom/gsd-wacom-device.c
diff options
context:
space:
mode:
authorBastien Nocera <hadess@hadess.net>2011-11-21 17:30:54 +0000
committerBastien Nocera <hadess@hadess.net>2011-11-22 18:16:38 +0000
commit2ae2c2002626f2886211ba874d9e42c22f1b6672 (patch)
tree464a98d953d03bf592a0bf222c8a80769876f50d /plugins/wacom/gsd-wacom-device.c
parenta6d45940f2cc3c860549756fb4e98a83b6c7357e (diff)
downloadgnome-settings-daemon-2ae2c2002626f2886211ba874d9e42c22f1b6672.tar.gz
wacom: Add type to string helper
Diffstat (limited to 'plugins/wacom/gsd-wacom-device.c')
-rw-r--r--plugins/wacom/gsd-wacom-device.c19
1 files changed, 19 insertions, 0 deletions
diff --git a/plugins/wacom/gsd-wacom-device.c b/plugins/wacom/gsd-wacom-device.c
index 6ab91878..14243fca 100644
--- a/plugins/wacom/gsd-wacom-device.c
+++ b/plugins/wacom/gsd-wacom-device.c
@@ -456,3 +456,22 @@ gsd_wacom_device_get_device_type (GsdWacomDevice *device)
return device->priv->type;
}
+
+const char *
+gsd_wacom_device_type_to_string (GsdWacomDeviceType type)
+{
+ switch (type) {
+ case WACOM_TYPE_INVALID:
+ return "Invalid";
+ case WACOM_TYPE_STYLUS:
+ return "Stylus";
+ case WACOM_TYPE_ERASER:
+ return "Eraser";
+ case WACOM_TYPE_CURSOR:
+ return "Wacom";
+ case WACOM_TYPE_PAD:
+ return "Pad";
+ default:
+ return "Unknown type";
+ }
+}