NavigationView prevents full navigation with an xbox contoller on Windows 10
See original GitHub issueDescribe the bug Having Settings visible on a NavigationView can prevent navigation to content in the page.
Steps to reproduce the bug
- In a new blank app, add the following.
<winui:NavigationView
IsSettingsVisible="False">
<Grid>
<StackPanel>
<RadioButton Content="Option 1" />
<RadioButton Content="Option 2" />
<RadioButton Content="Option 3" />
</StackPanel>
</Grid>
</winui:NavigationView>
- Connect an XBoxOne controller to a Windows desktop PC.
- Run the app and notice that it’s possible to use the controller to move focus to all 3 of the radio buttons.
- Close app.
- Change the [above] code to set
IsSettingsVisible="True"
. - Run the app again and notice that it’s NOT possible to use the controller to move focus to the radio button captioned Option 3.
Expected behavior It should be possible to use the xbox controller to get to every control on a page that can receive focus. I understand that the issue is likely due to the XY navigation system only having a single item at the bottom of the screen but as pressing down when the focus is on Option 2 this doesn’t explain why focus cannot move to the radio button directly beneath it (Option 3).
This is not an issue of an automatically implied [radiobutton]group being applied to the RadioButton
s.
- If it was it should still be possible to navigate between the options in the group.
- Changing the
RadioButton
s toButton
s (so there should be no implied grouping of related options) still produces the same behavior.
Screenshots n/a
Version Info
NuGet package version: Microsoft.UI.Xaml 2.2.190917002
Windows 10 version | Saw the problem? |
---|---|
Insider Build (xxxxx) | |
May 2019 Update (18362) | Yes |
October 2018 Update (17763) | |
April 2018 Update (17134) | |
Fall Creators Update (16299) | |
Creators Update (15063) |
Device form factor | Saw the problem? |
---|---|
Desktop | Yes |
Mobile | |
Xbox | |
Surface Hub | |
IoT |
Additional context This issue was discovered as part of investigation into https://github.com/microsoft/WindowsTemplateStudio/issues/3407 A workaround is also listed there. I appreciate that using an xbox controller to navigate a desktop app is a niche scenario but it is supported.
Issue Analytics
- State:
- Created 4 years ago
- Reactions:1
- Comments:5 (2 by maintainers)
This is indeed an issue with the XYFocus system. In the meantime you can use RadioButtons which work as expected:
@ranjeshj @StephenLPeters Should we mark this as WinUI 3 given that this would probably require a framework fix?
This issue is stale because it has been open 180 days with no activity. Remove stale label or comment or this will be closed in 5 days.