aboutsummaryrefslogtreecommitdiff
path: root/src/service.c
Commit message (Collapse)AuthorAgeFilesLines
* {CMakeLists.txt,src/service.c}: Make building against librda optional.Mike Gabriel2023-11-041-2/+7
|
* src/service.c: Ignore RDA's opinion when on Lomiri. Assume local session for ↵Mike Gabriel2023-08-311-1/+8
| | | | | | | Lomiri. Relates to: https://github.com/ArcticaProject/librda/issues/8 Relates to: https://gitlab.com/ubports/development/core/packaging/ayatana-indicators/ayatana-indicator-power/-/issues/7#note_1535612053
* Do not show when in a remote sessionRobert Tari2023-08-101-5/+11
| | | | fixes https://github.com/AyatanaIndicators/ayatana-indicator-power/issues/13
* src/service.c: stop special-casing Lomiri for level indicator typeRatchanan Srirattanamet2023-07-121-16/+2
| | | | | | | | | | | Since the change in level reporting from an action to menu attribute is a breaking change for Lomiri anyway, we might as well let Lomiri use .level indicator type. This reduces 1 special case for Lomiri, for which there is multiple throughout the codebase. We probably want to minimize this over time... Bug-UBports: https://gitlab.com/ubports/development/core/lomiri/-/issues/70
* src/service.c: also update devices section on phone profileRatchanan Srirattanamet2023-07-111-0/+1
| | | | | | | Since there's no longer an action to update the battery level, now the submenu itself has to also be updated on the phone. Bug-UBports: https://gitlab.com/ubports/development/core/lomiri/-/issues/70
* Do not use charge-aware icons in the menuRobert Tari2023-05-051-2/+2
|
* Use the device model name in the menuRobert Tari2023-05-051-2/+10
|
* src/service.c: Use level or progress IDO as neededRobert Tari2023-05-051-23/+28
|
* Show battery level for all devices (including bluetooth)Robert Tari2023-04-031-93/+60
| | | | fixes https://gitlab.com/ubports/development/core/packaging/ayatana-indicators/ayatana-indicator-bluetooth/-/issues/3
* src/service.c: Create a fake primary device icon on Lomiri if no device is ↵Robert Tari2023-02-171-0/+10
| | | | | | present fixes https://gitlab.com/ubports/development/core/packaging/ayatana-indicators/ayatana-indicator-power/-/issues/2
* Handle state changes for flashlight switchRobert Tari2023-02-121-2/+2
| | | | fixes https://gitlab.com/ubports/development/core/packaging/ayatana-indicators/ayatana-indicator-power/-/issues/5
* src/service.c: Fix auto brightness switchRobert Tari2022-11-131-3/+5
|
* Revert "Don't prioritize discharging items with no time estimate that have ↵Alfred Neumayer2022-11-121-8/+0
| | | | | | | | | | | | | | | more than 10% power remaining." As the battery in the Pixel 3a running 20.04 exposes itself without any time estimates, it gets hidden by the indicator unless below 10% of charge. The original commit message mentions low-power devices having no time estimates most probably due to lasting long, but (without an honest checkup of the upstream kernel sources) I doubt the kernel driver to distinguish between those capabilities in the power_supply properties, hence remove this artificial limit again. This reverts commit 522fdc6abbfee52dec5c6b0194cf87ffcc0f3dcd.
* src/service.c: Fix flashlight toggleRobert Tari2022-11-111-3/+5
| | | | fixes https://github.com/AyatanaIndicators/ayatana-indicator-power/issues/66
* Theming fix: Separate panel icons from the power menu iconsRobert Tari2022-11-101-3/+3
| | | | | | This fixes the broken theming issue where the Power Indicator menu shows the same icons as used by the panel, rather than the ones used elsewhere on the system. End result: makes any theme capable of becoming Ayatana-friendly without hacks
* src/service.c: Add tooltip support.Mike Gabriel2022-09-011-0/+2
|
* src/service.c: Assign copyright to Robert Tari, not AyatanaIndicators project.Mike Gabriel2021-11-181-1/+1
|
* src/: Typo fix in license header.Mike Gabriel2021-11-181-1/+1
|
* Pull in many fixes from the bionic branch. (#7)Rodney2021-08-281-7/+7
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * Pay attention to $SNAP prefix * Releasing 12.10.6+17.04.20161201-0ubuntu1 * give sorting priority to devices with power supplies * Releasing 12.10.6+17.04.20170116-0ubuntu1 * Remove old autostart files. * Use gmock module from cmake-extras. * Use coverage support from cmake-extras. * Add gcovr and lcov dependencies. * Use intltool support from cmake-extras. * Remove usage of extra GCOV variables. * Remove hard-coded -g compiler flag. * Releasing 12.10.6+17.04.20170210-0ubuntu1 * no change rebuild * Releasing 12.10.6+17.04.20170322-0ubuntu1 * Start indicator in systemd when indicators.target is started * Build for bionic * This is still xenial. * Update translations from launchpad too.
* handle service_set_notifier(NULL) gracefullycharles kerr2021-08-281-2/+6
|
* update copyright dates on changed files (again)charles kerr2021-08-281-6/+6
|
* fix notifier property in servicecharles kerr2021-08-281-0/+7
|
* make a SoundPlayer interface so we can mock it in the testscharles kerr2021-08-281-4/+34
| | | | | | | | this requires an annoying amount of scaffolding: 1. implement gst and mock classes to implement the SoundPlayer interface 2. modify notifier to take a SoundPlayer argument in its ctor 3. modify service to take a Notifier argument in its ctor instead of instantiating it on its own 4. change main to update the startup steps for player/notifier/service
* Don't prioritize discharging items with no time estimate that have more than ↵Marc Deslauriers2021-08-281-6/+14
| | | | | | | | | | | | | | 10% power remaining. Devices with no time estimates are most likely low-power devices that have long-lasting batteries, such as a mouse with AA batteries. For those type of devices that contain batteries that last weeks, there is no value in displaying their status in preference to devices that have a rapid charge/discharge cycle. However, there is value in knowing if the device has a battery that needs replacing imminently, so only display it if it falls to a 10% charge or under.
* Use prefixed libayatana-common symbolsRobert Tari2021-05-171-6/+6
|
* Always show indicator, use icon policy only on LomiriRobert Tari2021-05-031-0/+5
|
* Add Budgie desktop support.Robert Tari2021-05-031-1/+1
| | | | Fixes AyatanaIndicators/ayatana-indicator-power#2
* Add us to the copyright headersRobert Tari2021-05-031-0/+2
|
* Move redundant code portions into libayatana-common and build against it.Robert Tari2021-05-031-1/+1
|
* service.c: Drop indicator settings itemsRobert Tari2020-11-161-8/+0
|
* Fix deprecations and build warnings.Robert Tari2020-09-041-10/+4
| | | | Fixes AyatanaIndicators/ayatana-indicator-power#9.
* Replace x-canonical attributesRobert Tari2020-08-111-7/+7
|
* Do not divide by battery size if percent less than 0.01BirdZhang2020-08-061-2/+4
|
* src/service.c: Adapt indicator attribute for flashlight switch to ayatana-ido.Mike Gabriel2018-03-251-1/+1
|
* Added warning to avoid overheating of the LED.Jan Sprinz (NeoTheThird)2018-03-251-0/+7
| | | | | | | | | | | | | | | | | | | | | | | | Ported from UBports power indicator: commit ef020b31be15f1126d3e5ea5ec399179aad586b8 Author: Jan Sprinz (NeoTheThird) <neo@neothethird.de> Date: Sat Sep 16 16:02:50 2017 +0200 Forgot semicolon *blush* commit c8be2d9a142e17bdfa86ee68e23a18ba0680c244 Author: Jan Sprinz (NeoTheThird) <neo@neothethird.de> Date: Sat Sep 16 15:53:29 2017 +0200 Change var name commit 3d6a37503bafcbf397220dcfac5624a686f2f900 Author: Jan Sprinz (NeoTheThird) <neo@neothethird.de> Date: Sat Sep 16 14:24:05 2017 +0200 Added warning to avoid overheating of the LED Ported-by: Mike Gabriel <mike.gabriel@das-netzwerkteam.de>
* Add basic flashlight support.Marius Gripsgard2018-03-251-0/+13
| | | | | | | | | | | | | | | | | | | | Ported from UBPorts power indicator: commit efef6f25f378021c99b3078958482b3c4ffc43a2 Author: Marius Gripsgard <mariogrip@ubuntu.com> Date: Sun Aug 13 00:09:01 2017 +0200 Add support for other flashlight sysfs paths commit 3f4339876ddb586b75a73fab51a54b1d4d54fdd1 Author: Marius Gripsgard <mariogrip@ubuntu.com> Date: Fri Jul 28 21:23:54 2017 +0200 Add basic support for QCOM flashlight, Fixes https://github.com/ubports/ubports-touch/issues/79 This does not work on non QCOM devices Ported-by: Mike Gabriel <mike.gabriel@das-netzwerkteam.de>
* src/{service.c,utils.c}: Fix grammar flaw in zenity warning.Mike Gabriel2018-03-161-1/+1
|
* Add fallback code that produces a warning (using zenity), if we don't know ↵Mike Gabriel2018-03-151-0/+6
| | | | how to handle certain actions.
* src/service.c: Use desktop detection functions in 'on_statistics_activated()'.Mike Gabriel2018-03-121-3/+3
|
* Make URL dispatcher build-dependency optional and handle battery settings ↵Mike Gabriel2018-03-121-53/+3
| | | | request appropriately.
* Revert "Drop unnecessary dependency on Ubuntu's url-dispatcher."Mike Gabriel2018-03-121-1/+16
| | | | This reverts commit 0a9cc2a474ff583c928e109468f20330aae0603c.
* src/service.s: Fix x-canonical-type of the brightness slider building ↵Mike Gabriel2017-06-021-1/+1
| | | | against ayatana-ido.
* src/service.c: Prefer mate-power-statistics to gnome-power-statistics if in ↵Mike Gabriel2017-05-311-4/+14
| | | | a MATE session.
* src/service.c: Know about DESKTOP_SESSION xfce as well (not only about xubuntu).Mike Gabriel2017-05-311-1/+1
|
* Another fix-up for previous commits: keep org.ayatana.indicator namespace ↵Mike Gabriel2017-05-161-4/+4
| | | | for indicator types.
* One step back... Mimick Canonical's API. Use their namespace for item ↵Mike Gabriel2017-05-151-6/+6
| | | | attributes.
* Make device with power supply has higher sorting priority. (LP: #1100546)Charles Kerr2017-05-151-6/+22
|
* Fix bug that chose the wrong header icon if a connected device has a charge ↵Charles Kerr2017-05-151-1/+19
| | | | but its charging/discharging state is unknown. (LP: #1470080).
* Drop unnecessary dependency on Ubuntu's url-dispatcher.Mike Gabriel2015-11-121-16/+1
|
* Fork from Ubuntu's indicator-power code project.Mike Gabriel2015-11-121-9/+9
|