[gnome-settings-daemon] wacom: Add stylus _get_id() for debugging purposes



commit 186a68d924a24b38b75d193a316056e63e1211bf
Author: Bastien Nocera <hadess hadess net>
Date:   Wed Jan 25 11:37:52 2012 +0000

    wacom: Add stylus _get_id() for debugging purposes

 plugins/wacom/gsd-wacom-device.c |    8 ++++++++
 plugins/wacom/gsd-wacom-device.h |    1 +
 2 files changed, 9 insertions(+), 0 deletions(-)
---
diff --git a/plugins/wacom/gsd-wacom-device.c b/plugins/wacom/gsd-wacom-device.c
index 36a7420..062e0cf 100644
--- a/plugins/wacom/gsd-wacom-device.c
+++ b/plugins/wacom/gsd-wacom-device.c
@@ -224,6 +224,14 @@ gsd_wacom_stylus_get_stylus_type (GsdWacomStylus *stylus)
 	return WACOM_STYLUS_TYPE_UNKNOWN;
 }
 
+int
+gsd_wacom_stylus_get_id (GsdWacomStylus *stylus)
+{
+	g_return_val_if_fail (GSD_IS_WACOM_STYLUS (stylus), -1);
+
+	return stylus->priv->id;
+}
+
 #define GSD_WACOM_DEVICE_GET_PRIVATE(o) (G_TYPE_INSTANCE_GET_PRIVATE ((o), GSD_TYPE_WACOM_DEVICE, GsdWacomDevicePrivate))
 
 /* we support two types of settings:
diff --git a/plugins/wacom/gsd-wacom-device.h b/plugins/wacom/gsd-wacom-device.h
index 24b268b..8d5ad06 100644
--- a/plugins/wacom/gsd-wacom-device.h
+++ b/plugins/wacom/gsd-wacom-device.h
@@ -85,6 +85,7 @@ const char     * gsd_wacom_stylus_get_icon_name  (GsdWacomStylus *stylus);
 GsdWacomDevice * gsd_wacom_stylus_get_device     (GsdWacomStylus *stylus);
 gboolean         gsd_wacom_stylus_get_has_eraser (GsdWacomStylus *stylus);
 int              gsd_wacom_stylus_get_num_buttons(GsdWacomStylus *stylus);
+int              gsd_wacom_stylus_get_id         (GsdWacomStylus *stylus);
 GsdWacomStylusType gsd_wacom_stylus_get_stylus_type (GsdWacomStylus *stylus);
 
 /* Device types to apply a setting to */



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]