aboutsummaryrefslogtreecommitdiff
path: root/hardinfo2/arch/linux/common/inputdevices.h
diff options
context:
space:
mode:
authorLeandro A. F. Pereira <leandro@hardinfo.org>2006-06-22 13:23:29 +0000
committerLeandro A. F. Pereira <leandro@hardinfo.org>2006-06-22 13:23:29 +0000
commit88ad4b5628d05109881a5cdd88dce7a10b28434b (patch)
tree0349895264dfaa1fa0701f51841119cb67a98fd5 /hardinfo2/arch/linux/common/inputdevices.h
parentc44c0ec8d0bf75bf3ce1925e417d45d18743695c (diff)
Update vendor table, include vendor information in input devices
Diffstat (limited to 'hardinfo2/arch/linux/common/inputdevices.h')
-rw-r--r--hardinfo2/arch/linux/common/inputdevices.h32
1 files changed, 24 insertions, 8 deletions
diff --git a/hardinfo2/arch/linux/common/inputdevices.h b/hardinfo2/arch/linux/common/inputdevices.h
index 44a109ca..a3fb3e4a 100644
--- a/hardinfo2/arch/linux/common/inputdevices.h
+++ b/hardinfo2/arch/linux/common/inputdevices.h
@@ -103,14 +103,30 @@ scan_inputdevices(void)
gchar *strhash = g_strdup_printf("[Device Information]\n"
"Name=%s\n"
"Type=%s\n"
- "Bus=0x%x\n"
- "Vendor=0x%x\n"
- "Product=0x%x\n"
- "Version=0x%x\n"
- "Connected to=%s\n",
- name, input_devices[d].name,
- bus, vendor, product,
- version, phys);
+ "Bus=0x%x\n",
+ name,
+ input_devices[d].name,
+ bus);
+
+ const gchar *url = vendor_get_url(name);
+ if (url) {
+ strhash = g_strdup_printf("%s"
+ "Vendor=%s (%s)\n",
+ strhash,
+ vendor_get_name(name),
+ url);
+ } else {
+ strhash = g_strdup_printf("%s"
+ "Vendor=%x\n",
+ strhash,
+ vendor);
+ }
+
+ strhash = g_strdup_printf("%s"
+ "Product=0x%x\n"
+ "Version=0x%x\n"
+ "Connected to=%s\n",
+ strhash, product, version, phys);
g_hash_table_insert(devices, tmp, strhash);
g_free(phys);