-
Notifications
You must be signed in to change notification settings - Fork 54
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Xbox Controller is not working in Webview2 in UWP [WinUI2] #4366
Comments
Hi @Sentry-Thibault, I was able to repro this. It's been added to our backlog! I did find this bug (#3025) which may be related. I wonder if this is specifically a UWP issue, or if this works in a WinForms app. I know you need a UWP app for your scenario since you're building an app for Xbox. If you open up a DevTools window like the user in that bug tried, does the behavior change? |
Hi @jennifer-jacobs, Thanks for reply. It seems to not working with dev tools window focused in my case. |
Hi, If I add Xbox controller input detection UI in my UWP app (like : https://sandervandevelde.wordpress.com/2016/02/29/using-your-xbox-one-controller-in-a-uwp-app/) It works. |
Hi @Sentry-Thibault, Some info on porting your app from other APIs to GameInput that might be helpful: https://learn.microsoft.com/en-us/gaming/gdk/_content/gc/input/porting/input-porting Hopefully this works for you! |
Hi @jennifer-jacobs, Thanks for sharing this but I'm wondering how to integrate this. I'm in the fog right now ^^. [EDIT] Thanks |
Hey @Sentry-Thibault, I should be able to test this out locally next week if that doesn't work for you. |
@jennifer-jacobs It doesn't work for me unfortunaly. |
@jennifer-jacobs Up please |
@Sentry-Thibault I just tried this on Win11 and it works on my machine. It's possible I have other tools installed however that are making this possible. Just to confirm, you installed the gaming services package on your Win10 machine and then re-tried the scenario and it didn't work, correct? How do you have your Xbox controller connected to your PC? Through bluetooth or through the Xbox wireless adapter? |
|
For what it's worth, I have noticed that if you create a UWP/WebView2 application, Gamepad input just works when running the app on an actual Xbox, but does not work at all when running on desktop. If I remember right though, this same behavior happened with the original WebView, so I think it might be a UWP issue. |
@jennifer-jacobs Up please |
@Sentry-Thibault I was able to repro this and it's been added to our backlog! |
I can confirm this , this is an existing issue too on our old
We are planning to move away from |
Hi, I am having the same issue using WebView2 embedded in a WinUI 3 application running on Windows 11. When I navigate to https://gamepad-tester.com/, it only registers input when I press the Xbox button on the controller - so there is some communication happening. No other button or stick input works at all however. @jennifer-jacobs You mentioned that you've been able to repro the issue and it's been added to the backlog. Is there an ETA for addressing it or a workaround I could try in the mean time? It's disappointing not to be able to support gamepad input as it severely limits the options for gaming with WebView2. |
What happened?
I've created a simple UWP application with WinUI 2 according to the official documentation.
The webview is loading the URL https://gamepad-tester.com/
I connected a Gamepad (Xbox One Controller) to my computer.
The gamepad works fine in Google Chrome and Microsoft Edge (Chromium).
But the gamepad is not working in Webview2.
See also: #1318
Importance
Blocking. My app's basic functions are not working due to this issue.
Runtime Channel
Stable release (WebView2 Runtime)
Runtime Version
No response
SDK Version
No response
Framework
WinUI2/UWP
Operating System
Windows 10
OS Version
19045.3930
Repro steps
Create a simple WinUI2 UWP application and add a webview2 targeting the URL https://gamepad-tester.com/
Repros in Edge Browser
No
Regression
No, this never worked
Last working version (if regression)
No response
AB#48930763
The text was updated successfully, but these errors were encountered: