summaryrefslogtreecommitdiff
path: root/src/freebsd/up-device-supply.c
Commit message (Collapse)AuthorAgeFilesLines
* Move battery type decoding into common fileBenjamin Berg2022-06-071-30/+2
|
* freebsd: Use correct up_make_safe_string definitionBenjamin Berg2022-06-031-0/+2
|
* common: Add a file with common helperBenjamin Berg2022-05-251-3/+3
| | | | | | This removes some code duplication between the linux and freebsd backend. And, this file could become home to other small helper functions in the future.
* device: Flag refresh reasonBenjamin Berg2022-05-091-2/+2
| | | | | | | The reason of a refresh may be interesting to special case certain situation (e.g. discontinuity of charge after wakeup, polling again after an event). As such, add an enum parameter that signals the reason for the refresh.
* freebsd: Fix a few minor warningsBenjamin Berg2022-04-201-2/+1
|
* device: Handle device coldplug using GInitableBenjamin Berg2022-04-201-13/+0
| | | | | | | 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.
* bsd*: Allow building on linuxBenjamin Berg2022-04-011-0/+8
| | | | | | | Guard platform specific code and add in a few extra definitions so that the backends can at least be partially compiled on linux. This is for testing purposes, if we could build against a proper image that would also be acceptable.
* device: Move daemon/native object into construct only propertiesBenjamin Berg2022-04-011-3/+6
| | | | | | Rather than this weird situation where they are immediately passed in through the "coldplug" method. Doing this is the first step to make UpDevice into an initable object (removing the "coldplug" method).
* all: convert value from g_get_real_time() to secondsEvangelos Foutras2014-10-081-1/+1
| | | | | | | | Commit 5ddfe0d (all: Use g_get_real_time() when possible) replaced calls to g_get_current_time() with g_get_real_time(), however, we also need to convert the return value from microseconds to seconds. Signed-off-by: Richard Hughes <richard@hughsie.com>
* all: Use g_get_real_time() when possibleBastien Nocera2014-09-241-5/+2
| | | | Instead of a call to g_get_current_time().
* daemon: Replace "on-low-battery" propertyBastien Nocera2013-10-141-28/+0
| | | | With "warning-level" property.
* freebsd: Remove useless finalizeBastien Nocera2013-10-141-17/+0
| | | | It was just chaining up.
* Port from EggDebug to the GLib built-in logging frameworkRichard Hughes2010-11-011-8/+6
|
* up-device-supply.c: Fix #27902 Bug - Daemon Segmentation FaultMariusz Ceier2010-07-021-3/+3
| | | | | | | | | In linux backend, g_object_set was called with wrong argument types for time-to-empty,time-to-full and percentage properties. This patch uses explicit casts in the same way as freebsd backend. Signed-off-by: Mariusz Ceier <mceier@gmail.com>
* Fix up the FreeBSD backend compileMichael Biebl2010-02-231-1/+1
| | | | Signed-off-by: Richard Hughes <richard@hughsie.com>
* trivial: rename the new libupower 'type' to 'kind' to avoid clashing with ↵Richard Hughes2010-01-261-9/+9
| | | | GObject generated names
* trivial: convert freebsd private object to using upower prefix (no ABI or ↵Richard Hughes2010-01-181-19/+19
| | | | API changes)
* trivial: switch to using the new enum names internally (no ABI or API break)Richard Hughes2010-01-181-22/+22
|
* trivial: DkpDevice -> UpDevice (no ABI or API break)Richard Hughes2010-01-181-74/+74
|
* trivial: Rename a lot of the source files from dkp-foo to up-foo, no API or ↵Richard Hughes2010-01-181-0/+542
ABI changes