hal: Branch 'master'
David Zeuthen
david at kemper.freedesktop.org
Sun Feb 25 18:29:24 PST 2007
hald/linux/device.c | 33 ++++++++++++++++++++++++++++++++-
1 files changed, 32 insertions(+), 1 deletion(-)
New commits:
diff-tree 10834e4474c21c2b474b4760e48ff809dd717df9 (from f30d5efd1458cc43ec90563ea4028a26fdef7689)
Author: David Zeuthen <davidz at redhat.com>
Date: Sun Feb 25 21:29:20 2007 -0500
make Device.Rescan() work for refreshing button state when using ACPI input
diff --git a/hald/linux/device.c b/hald/linux/device.c
index 1db5432..b3811f6 100644
--- a/hald/linux/device.c
+++ b/hald/linux/device.c
@@ -3505,10 +3505,41 @@ out:
;
}
+static void
+dev_rescan_device_done (HalDevice *d,
+ guint32 exit_type,
+ gint return_code,
+ char **error,
+ gpointer data1,
+ gpointer data2)
+{
+ HAL_INFO (("dev_rescan_device_done: exit_type=%d, return_code=%d", exit_type, return_code));
+}
+
gboolean
dev_rescan_device (HalDevice *d)
{
- return FALSE;
+ gboolean ret;
+
+ ret = FALSE;
+
+ /* rescan button state on Rescan() */
+ if (hal_device_property_get_bool (d, "button.has_state")) {
+
+ hald_runner_run (d,
+ "hald-probe-input",
+ NULL,
+ HAL_HELPER_TIMEOUT,
+ dev_rescan_device_done,
+ NULL,
+ NULL);
+
+ ret = TRUE;
+ goto out;
+ }
+
+out:
+ return ret;
}
More information about the hal-commit
mailing list