maniacx / Bluetooth-Battery-Meter

A Gnome extension featuring indicator icons in system tray, serving as meter for Bluetooth device battery levels and providing detailed battery levels via icon/text in the Bluetooth quick settings menu.
https://extensions.gnome.org/extension/6670/bluetooth-battery-meter/
GNU General Public License v3.0
99 stars 11 forks source link

Allowlist to override 'supportedIcons' check for less common peripherals #39

Open Excigma opened 1 week ago

Excigma commented 1 week ago

Thanks for this extension. It works well with my earbuds, however, my laptop has a stylus with bluetooth functionality for the button at the top, additionally, bluetooth is also useful for checking the precise battery level of the stylus.

The stylus shows up with my battery meters in GNOME but is not shown by the extension. I had a quick skim over the code and suspect it may be due to supportedIcons not whitelisting the icon: https://github.com/maniacx/Bluetooth-Battery-Meter/blob/09928b482e27c7996fbf054eb9c471a4a9631c61/lib/bluetoothToggle.js#L12C7-L12C21

Unfortunately, my stylus just uses the generic bluetooth icon, so adding it to supportedIcons might be a no-go: image

Stylus power shown in GNOME settings (unfortunately my mouse and keyboard doesn't show up either as they don't use bluetooth, so it might be outside the scope of this issue + extension): image

Some possible solutions I thought of were:

image

Thank you!

maniacx commented 1 week ago

Yes. there was another user with bose headphone showing, generic icon. I will try to implement what you have suggested. Probably end of next week.