summaryrefslogtreecommitdiff
path: root/src/freebsd/up-device-supply.c
diff options
context:
space:
mode:
authorBenjamin Berg <bberg@redhat.com>2022-04-12 18:07:57 +0200
committerBenjamin Berg <bberg@redhat.com>2022-04-20 14:30:00 +0200
commit25ddb11f084a5f3e3004c1addeb97de67351fd8a (patch)
treeb4422b0d3d7cd838adc58c7acc49ff498f221ba0 /src/freebsd/up-device-supply.c
parent20fed261f1288c0683dec9679066ee9e91b87112 (diff)
downloadupower-25ddb11f084a5f3e3004c1addeb97de67351fd8a.tar.gz
device: Handle device coldplug using GInitable
There are only a few cases where we separate construction and coldplug. Porting to GInitable is relatively natural here and makes the code a little nicer overall. In the case that immediate coldplug/initialization is not desired, we can still split the operations.
Diffstat (limited to 'src/freebsd/up-device-supply.c')
-rw-r--r--src/freebsd/up-device-supply.c13
1 files changed, 0 insertions, 13 deletions
diff --git a/src/freebsd/up-device-supply.c b/src/freebsd/up-device-supply.c
index e83c39d..0400d6b 100644
--- a/src/freebsd/up-device-supply.c
+++ b/src/freebsd/up-device-supply.c
@@ -488,16 +488,3 @@ up_device_supply_class_init (UpDeviceSupplyClass *klass)
device_class->coldplug = up_device_supply_coldplug;
device_class->refresh = up_device_supply_refresh;
}
-
-/**
- * up_device_supply_new:
- **/
-UpDeviceSupply *
-up_device_supply_new (UpDaemon *daemon,
- GObject *native)
-{
- return UP_DEVICE_SUPPLY (g_object_new (UP_TYPE_DEVICE_SUPPLY,
- "daemon", daemon,
- "native", native,
- NULL));
-}