-
Notifications
You must be signed in to change notification settings - Fork 1.8k
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
Window glitches when dragging app between monitors with different scaling #11777
Comments
If you try this in a WinUI application without MAUI, what happens? |
We've moved this issue to the Backlog milestone. This means that it is not going to be worked on for the coming release. We will reassess the backlog following the current release and consider this item at that time. To learn more about our issue management process and to have better expectation regarding different types of issues you can read our Triage Process. |
Good question. I tried with a new app from the "Blank App, Packaged (WinUI 3 in Desktop)" template, changed it to .net7 to match the Maui project and was not able to reproduce the issue there. I also tried adding a ScrollViewer and some TextBoxes there and still no repro. |
I see the same behavior on my machine. One display is at 200% and a second one at 150%. I see different kinds of flickering effects and the content seems to toggle between both DPI settings (= sizes). Based on the behavior my assumption is, that the MAUI window is doing some resizing strategy before the user releases the mouse cursor on the second screen
When I break the execution I always see stack trace like this: |
I have the same issue with Maui Blazor App. One monitor is at 125% and the other is at 100%. When I drag the Maui app from the 125% monitor to the 100%, it gets stuck halfway, flickering as if re-rendering but the app itself is unresponsive and has to be killed off. On the other hand, if I drag from 100% to 125% the problem does not show up. As long as the app starts in a 100% scaling monitor it seems okay to be dragged afterward but not if it starts up in a 125% scaled monitor. You cannot drag back from 125% to 100%. |
I have the same issue with Maui Blazor App. any update? |
This mentions the possible issue. Calculating the Width, Height, X, and Y could be causing it to redraw and freak out. |
Addition to my comment #14597 (comment)
I will get this when I move MAUI window from a monitor with 150% scaling to another one with 100% scaling:
It seems to me that updating bindable properties in such hot path is not a good idea. . |
maui/src/Controls/src/Core/HandlerImpl/Window/Window.Impl.cs Lines 209 to 212 in 48d0294
These lines are causing performance regression imo @jonathanpeppers pinging for help |
The picture of a stack trace above shows this is called:
Hoping this was profiled in So, is this what is happening?
Regression from what? .NET 6? |
Unfortunately i didn't save that file, wasn't expecting it be needed. And yes it was in Release mode. Here is another run I did in Release mode. Maui.Controls.Sample_Xl8BmnifAD.mp4Here is the profile session for above :
I think based on #4942 yes. |
Sorry but we have to revert the PR that fixes this issue. We are working in improving the related fix to be merged on main. |
Description
Dragging a Maui app between different monitor causes visual glitches and eventually stops responding. See attached video to see what I mean: screen-capture.webm. In the video I'm just recording my 2nd monitor; the laptop screen is below it so that's where the app is when I drag it off screen below. In the end I need to ctrl+alt+delete to get to the task manager and force close it because everything stops responding.
Steps to Reproduce
Expected results:
You can freely move the app around and it will work fine.
Actual results:
After moving from one monitor to the other a few times, it will break. Sometimes the app window flashes around wildly, sometimes just the edge of the window twitches - see video in description.
Link to public reproduction project repository
Can repro in the Maui template app
Version with bug
7.0 (current)
Last version that worked well
Unknown/Other
Affected platforms
Windows
Affected platform versions
Windows 10 19043.2251
Did you find any workaround?
Don't use different scaling
Relevant log output
No response
The text was updated successfully, but these errors were encountered: