Giter Site home page Giter Site logo

tommaier123 / xbatterystatus Goto Github PK

View Code? Open in Web Editor NEW
166.0 5.0 15.0 16.03 MB

A clean and lightweight tray app that displays the battery level of most bluetooth game controllers

License: GNU General Public License v3.0

C# 100.00%
bluetooth game-controller tray-icon

xbatterystatus's Issues

Show numeric battery level in icon

Is it possible to have the battery level in numbers in the icon itself, so you dont have to hover over it to see the exact level?
That would be a handy maybe optional setting I would appreciate.

Asking for .net installation w/o specifying which version

Hello, I'm trying to install xbatterystatus.msi and when trying to run it it asks if I want to install .net, but doesn't specify which version it wants and doesn't seem to check for the version I already have installed (4.8).

Would really appreciate some help into knowing how I can get this working please.

Thank you beforehand!
image_2024-03-23_113741084

[BUG?] Showing wrong battery status?

Hi, I have found your app in Microsoft forums, when was looking for valid battery charge value displaying.

Installed .NET 5 SDK and your app via winget. After 6 hours of gaming with vibrations, gamepad still shows in Windows, your App tray, Bluetooth devices 100%.

I am using Xbox Elite Series 2 Controller connected via Bluetooth. I am using PC with Wi-Fi/Bluetooth antenna. (WiFi and Bluetooth enabled in same time) on Windows 11 Pro 22H2 (OS Build 22621.3007); App version 1.2.1

I have installed latest gamepad update by Xbox Accessories app.

image

image

image

dont shows battery status

if i turn off bluetooth and turn on it again, battery status will not show status. it fixes after restart program only.

program stopped

i have this problem

""operation successful: the process "Xbatt..." with PID 16460 has been stopped
invalid number of parameters
0 files copied ""

(sorry for my bad english)

Capture d’écran 2022-06-19 103125

Tray icon disappeared

I've tried your app but sadly the tray icon showed up for few seconds and disappeared (was still running in the background apparently), I'm running Windows 11 and I've got the official xbox USB adapter.

1.3.2 Trojan

Windows anti-virus flagged version 1.3.2 as a Trojan:

image

Wrong file version

The .exe file is 1.2.1, but the systray icon and windows installed programs says its 1.3.2

image

App launch issue

I've installed the .NET 5 Desktop Runtime, after that installing app through install.bat with admin right, but when I launch the app; this dialog shows the error.
Screenshot 2021-07-28 091949

Light/Dark mode autodetection uses in-window colour instead of taskbar

The light/dark mode colour is chosen based on the selection in Windows settings. This makes the icon unusable if you want light mode windows but a dark taskbar (i.e. default in Windows 10) as the icon will be black on black and essentially invisible.

Would it be possible to add a manual setting of icon colour?

Winget package

It'd be nice to be able to install this via WinGet so we can easily get updates without having to do it manually.

Cant't install

I already installed .net 5 but once i run install.bat (as admin) this happens:

Screenshot (96)

and then after i click "OK"

Screenshot (97)

i also noticed that i do not have a file called XBatteryStatus.exe

tray icon only white color

Both light and dark mode in win11 , tray icon only white color, can‘t dynamic display.

It's hard to read, hope u updating , thx.

GDI object memory leak

There seems to be a memory leak in XBatteryStatus w.r.t. GDI objects.

After running XBatteryStatus for a while it will crash with the following exception:

System.Runtime.InteropServices.ExternalException (0x80004005): A generic error occurred in GDI+.
at System.Drawing.Bitmap.GetHicon()
at XBatteryStatus.MyApplicationContext.GetIcon(Int32 val, String s) in C:\Users\Max\source\repos\tommaier123\XBatteryStatus\XBatteryStatus\MyApplicationContext.cs:line 461
at XBatteryStatus.MyApplicationContext.ReadBattery() in C:\Users\Max\source\repos\tommaier123\XBatteryStatus\XBatteryStatus\MyApplicationContext.cs:line 331
at System.Threading.Tasks.Task.<>c.b__140_0(Object state)

Tracking the number of GDI objects in task manager show it steadily increasing. Currently it is reporting 4,517 GDI objects for me, which is more then any other program by a large margin. To my understanding, Windows will limit the number of handles at some point, causing the exception above.

Could this exception be due to the handle given by System.Drawing.Bitmap.GetHicon() never being destroyed? I don't see any calls to DestroyIcon in the code. There might be other leaks, but this is my primary suspect.

For reference see the example code snippet calling DestroyIcon:
https://learn.microsoft.com/en-us/dotnet/api/system.drawing.bitmap.gethicon?view=net-8.0

And the issue mentioned more explicitly here:
https://stackoverflow.com/questions/30979653/icon-fromhandle-should-i-dispose-it-or-call-destroyicon

Love the project. Hope it can be fixed.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.