Skip to content
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 UWP app: Pointer mode does not work properly when scaling is set to default (200 %) #9076

Closed
vsfeedback opened this issue Nov 13, 2023 · 4 comments
Labels
bug Something isn't working team-Controls Issue for the Controls team

Comments

@vsfeedback
Copy link

This issue has been moved from a ticket on Developer Community.


The UWP app is configured for the Xbox so that the pointer mode is only enabled when requested (RequiresPointerMode = ApplicationRequiresPointerMode.WhenRequested). The scaling is set to default (200 % for UWP apps). One page was created with a ScrollViewer and one with a WebView2 element. Both elements have the properties "RequiresPointer=WhenEngaged" and "IsFocusEngagementEnabled=True". As soon as the elements receive the focus and the pointer mode is activated (IsFocusEngaged = True), the pointer appears. However, the pointer can only be used in 25 % of the area of the element at the top left. As soon as scaling is disabled (ApplicationViewScaling.TrySetDisableLayoutScaling(true)) and the app is displayed at 100 %, the pointer can be navigated over the entire area of the element.


Original Comments

Feedback Bot on 11/12/2023, 05:55 PM:

(private comment, text removed)


Original Solutions

(no solutions)

@microsoft-github-policy-service microsoft-github-policy-service bot added the needs-triage Issue needs to be triaged by the area owners label Nov 13, 2023
@duncanmacmichael duncanmacmichael added the bug Something isn't working label Nov 13, 2023
@remokeitel
Copy link

This is an UWP issue, not a WinUI issue!

Example with pointer issue:

App.xaml.cs:

public App()
{
    this.InitializeComponent();
    this.Suspending += OnSuspending;

    if (AnalyticsInfo.VersionInfo.DeviceFamily == "Windows.Xbox")
    {
        this.RequiresPointerMode = ApplicationRequiresPointerMode.WhenRequested;
        //ApplicationViewScaling.TrySetDisableLayoutScaling(true);
    }
}

MainPage.xaml:

<Grid>
    <Grid.RowDefinitions>
        <RowDefinition Height="Auto" />
        <RowDefinition Height="*" />
    </Grid.RowDefinitions>
    <TextBox Grid.Row="0" Text="Test" />
    <ScrollViewer
        x:Name="ScrollViewer"
        Grid.Row="1"
        IsFocusEngagementEnabled="True"
        RequiresPointer="WhenEngaged"
        GotFocus="ScrollViewer_GotFocus">
        <StackPanel>
            <TextBlock Text="Hello" />
        </StackPanel>
    </ScrollViewer>
</Grid>

MainPage.xaml.cs:

public MainPage()
{
    this.InitializeComponent();
}

private void ScrollViewer_GotFocus(object sender, RoutedEventArgs args)
{
    ScrollViewer.IsFocusEngaged = true;
}

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

1.0.2088.41

Framework

WinUI2/UWP

Operating System

Xbox

OS Version

10.0.25398.2538

@bpulliam bpulliam added team-Controls Issue for the Controls team and removed needs-triage Issue needs to be triaged by the area owners labels Nov 16, 2023
@ranjeshj
Copy link
Contributor

Please see this note regarding WinUI2 issues. Closing as not planned.
https://github.com/microsoft/microsoft-ui-xaml/blob/main/docs/contribution_handling.md#winui-2

@ranjeshj ranjeshj closed this as not planned Won't fix, can't repro, duplicate, stale Nov 18, 2023
@remokeitel
Copy link

This is business critical, because my commercial app is not working without fixing the issue! I need WebView2 for the use case. On Xbox there are no alternatives of using UWP.

@microsoft-github-policy-service microsoft-github-policy-service bot added the needs-triage Issue needs to be triaged by the area owners label Nov 20, 2023
@duncanmacmichael
Copy link
Member

Hi @remokeitel, thank you so much for opening this and bringing it to our attention. Our intention with WinUI2 bugs is to address them if they severely impact our business priorities, such as if a UWP bug caused a system vulnerability, but I can see why you understood the note the way you did. Apologies if this was confusing - I've updated the wording to make things a little clearer (see this PR: #9129). In the meantime, I'm sorry but this bug is not on our plan to fix.

@bpulliam bpulliam removed the needs-triage Issue needs to be triaged by the area owners label Dec 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working team-Controls Issue for the Controls team
Projects
None yet
Development

No branches or pull requests

5 participants