Repository navigation
feat: controller-battery-bar, controller battery as a ring in the bar - #29
Open
Amnesia1000 wants to merge 1 commit into
Open
Amnesia1000 wants to merge 1 commit into
Amnesia1000 wants to merge 1 commit into
Conversation
Show the battery of connected game controllers as a ring in the bar: it empties as the level drops, keeps the percentage inside, and colours the ring green above 30%, amber down to 10% and red below. Clicking it opens a popout with each controller's name, charge state, energy, draw, health, MAC address and sysfs device. The widget only draws in the panel, so it is visible while playing fullscreen games, unlike the desktop widget from controller-battery which this is derived from (MIT, credited in the LICENSE).
Amnesia1000
force-pushed
the
plugin/controller-battery-bar
branch
from
November 8, 2026 13:13
615c6a9 to
3078d78
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a new standalone plugin that shows the battery of connected game controllers as a ring in the bar.
Why a separate plugin
Following up on #28: the existing
controller-batteryplugin draws a desktop widget, which is easy to miss while a game is running fullscreen, and the controller is usually turned off right after playing. This plugin is a separate package that draws only in the panel and leaves the other plugin completely untouched.What it shows
%sign).It is meant as a more graphical, colour-coded alternative to the generic battery indicator the system provides.
Implementation notes
Devices.qmldetects controllers from UPower (GamingInputplus sysfs/model matching), reusing the approach fromcontroller-battery; the MIT attribution is kept in theLICENSEfile.metadata.jsonregisters a singlebarWidgetsentry (controllerBatteryBar) withcomponentandpopout, so it slides in through the shell's normal popout container.Validated with
scripts/validate.pyand the index regenerated withscripts/build_index.py.@0xSolanaceae @ladybug-me