mirror of
https://gitlab.freedesktop.org/upower/upower.git
synced 2025-12-20 09:00:03 +01:00
lib: Fix possible warning when type changes
UpDevice on the daemon side has a "type" property, but the libupower-glib object has a "kind" type instead. Translate that.
This commit is contained in:
parent
c33729ad2c
commit
aa62f6a15c
1 changed files with 4 additions and 1 deletions
|
|
@ -102,7 +102,10 @@ G_DEFINE_TYPE (UpDevice, up_device, G_TYPE_OBJECT)
|
||||||
static void
|
static void
|
||||||
up_device_changed_cb (UpDeviceGlue *proxy, GParamSpec *pspec, UpDevice *device)
|
up_device_changed_cb (UpDeviceGlue *proxy, GParamSpec *pspec, UpDevice *device)
|
||||||
{
|
{
|
||||||
g_object_notify (G_OBJECT (device), pspec->name);
|
if (g_strcmp0 (pspec->name, "type") == 0)
|
||||||
|
g_object_notify (G_OBJECT (device), "kind");
|
||||||
|
else
|
||||||
|
g_object_notify (G_OBJECT (device), pspec->name);
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue