[gnome-settings-daemon/wip/hadess/power-notifications-device-types: 5/6] power: Add comment about skipped types in low battery notifications
- From: Benjamin Berg <bberg src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-settings-daemon/wip/hadess/power-notifications-device-types: 5/6] power: Add comment about skipped types in low battery notifications
- Date: Thu, 19 Aug 2021 15:29:35 +0000 (UTC)
commit c6a669bbfc1048984b57a801c7453a03a47a63cb
Author: Bastien Nocera <hadess hadess net>
Date: Thu Aug 19 16:33:34 2021 +0200
power: Add comment about skipped types in low battery notifications
Those device types that exist in upower (and gnome-bluetooth) don't have
a user-friendly precise name that we could use to show in the
notification so fallback to the generic name instead.
eg. a "Wearable" could be a watch, or a number of other devices, but
end-users don't know what a "wearable" is in Bluetooth parlance.
plugins/power/gsd-power-manager.c | 7 +++++++
1 file changed, 7 insertions(+)
---
diff --git a/plugins/power/gsd-power-manager.c b/plugins/power/gsd-power-manager.c
index 97c8d05a..76f9df8c 100644
--- a/plugins/power/gsd-power-manager.c
+++ b/plugins/power/gsd-power-manager.c
@@ -501,6 +501,13 @@ static const struct {
const char *crit_body;
const char *crit_body_unk;
} peripheral_battery_notifications[] = {
+ /* Intentionally skipped types (too uncommon, and name too imprecise):
+ * UP_DEVICE_KIND_MODEM
+ * UP_DEVICE_KIND_NETWORK
+ * UP_DEVICE_KIND_VIDEO
+ * UP_DEVICE_KIND_WEARABLE
+ * UP_DEVICE_KIND_TOY
+ */
{
.kind = UP_DEVICE_KIND_MOUSE,
/* TRANSLATORS: notification title, a wireless mouse is low or very low on power */
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]