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

fix(macOS): Prevent pointer over event originating from other window #18688

Merged
merged 1 commit into from
Nov 6, 2024

Conversation

spouliot
Copy link
Contributor

@spouliot spouliot commented Nov 4, 2024

GitHub Issue (If applicable): closes #16399

PR Type

What kind of change does this PR introduce?

  • Bugfix

What is the current behavior?

Events, like mouse move, on other windows on top of the app would be considered.

What is the new behavior?

Events are only received when the current application is active.

PR Checklist

Please check if your PR fulfills the following requirements:

Other information

Internal Issue (If applicable):

@unodevops
Copy link
Contributor

🤖 Your Docs stage site is ready! Visit it here: https://unodocsprstaging.z13.web.core.windows.net/pr-18688/index.html

@jeromelaban
Copy link
Member

@Mergifyio backport release/stable/5.5

Copy link
Contributor

mergify bot commented Nov 5, 2024

backport release/stable/5.5

✅ Backports have been created

@nventive-devops
Copy link
Contributor

The build 145987 found UI Test snapshots differences: android-28-net8: 20, android-28-net8-Snap: 45, ios: 12, ios-Snap: 42, skia-gtk-screenshots: 61, skia-linux-screenshots: 62, skia-windows-screenshots: 72, wasm: 564, wasm-automated-net9.0-UWP-Default-automated: 28, wasm-automated-net9.0-UWP-RuntimeTests-0: 0, wasm-automated-net9.0-UWP-RuntimeTests-1: 0, wasm-automated-net9.0-UWP-RuntimeTests-2: 0, wasm-automated-net9.0-WinUI-Benchmarks-automated: 0, wasm-automated-net9.0-WinUI-RuntimeTests-0: 0, wasm-automated-net9.0-WinUI-RuntimeTests-1: 0, wasm-automated-net9.0-WinUI-RuntimeTests-2: 0

Details
  • android-28-net8: 20 changed over 829

    🚨🚨 Comparison Details (first 20) 🚨🚨
    • DecimalFormatterTest_UITests_Shared_Microsoft_UI_Xaml_Controls_NumberBoxTests_NumberBoxPage
    • Detereminate_ProgressRing_Validation75_[#FF0000_#008000_#008000_#008000]_Progress-Ring-Value-75
    • ListView_SelectedItems_SamplesApp_Windows_UI_Xaml_Controls_ListView_ListViewSelectedItems
    • ProgressRing_IsEnabled_Running_UITests_Windows_UI_Xaml_Controls_ProgressRing_WindowsProgressRing_GH1220
    • ProgressRing_Visibility_Collapsed_UITests_Windows_UI_Xaml_Controls_ProgressRing_WindowsProgressRing_GH1220
    • ValidateResourceLoader_Simple_UITests_Shared_Windows_ApplicationModel_Resources_ResourceLoader_ResourceLoader_Simple
    • Detereminate_ProgressRing_Validation50_[#FF0000_#008000_#008000_#FF0000]_Progress-Ring-Value-50
    • When_ExtendedSelectionWithoutItemClick_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
    • MinMaxTest_UITests_Shared_Microsoft_UI_Xaml_Controls_NumberBoxTests_NumberBoxPage
    • TextBox_CharacterCasingLower_ShouldBeAllLower_Test_UITests_Shared_Windows_UI_Xaml_Controls_TextBoxTests_TextBox_CharacterCasing
    • When_Parent_PointerMoved_After_drag_on_non-scrolling_ScrollViewer
    • When_Parent_PointerMoved_After_drag_on_ScrollViewer_-_touch
    • When_SingleSelectionWithoutItemClick_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
    • Detereminate_ProgressRing_Validation25_[#FF0000_#008000_#FF0000_#FF0000]_Progress-Ring-Value-25
    • When_SingleSelectionWithItemClick_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
    • FlyoutTest_Target_Uno_UI_Samples_Content_UITests_Flyout_Flyout_Target
    • SequentialAnimations_SamplesApp_Windows_UI_Xaml_Media_Animation_SequentialAnimationsPage
    • UpDownEnabledTest_UITests_Shared_Microsoft_UI_Xaml_Controls_NumberBoxTests_NumberBoxPage
    • WebView_NavigateToAnchor_Initial
    • When_NoSelection_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
  • android-28-net8-Snap: 45 changed over 1066

    🚨🚨 Comparison Details (first 20) 🚨🚨
    • Image_UITests_Windows_UI_Xaml_Controls_ImageTests_SvgImageSource_Icons_UITests_Windows_UI_Xaml_Controls_ImageTests_SvgImageSource_Icons
    • ListView_ListView_KeyboardInterception_UITests_Windows_UI_Xaml_Controls_ListView_ListView_KeyboardInterception
    • RatingControl_UITests_Microsoft_UI_Xaml_Controls_RatingControlTests_RatingControlPage_UITests_Microsoft_UI_Xaml_Controls_RatingControlTests_RatingControlPage
    • ListView_ListView_With_ListViews_Count_Measure_UITests_Shared_Windows_UI_Xaml_Controls_ListView_ListView_With_ListViews_Count_Measure
    • NavigationView_MUXControlsTestApp_NavigationViewTopNavOnlyPage_MUXControlsTestApp_NavigationViewTopNavOnlyPage
    • NavigationView_MUXControlsTestApp_NavigationViewTopNavPage_MUXControlsTestApp_NavigationViewTopNavPage
    • Pickers_UITests_Windows_UI_Xaml_Controls_CalendarView_CalendarView_Theming_UITests_Windows_UI_Xaml_Controls_CalendarView_CalendarView_Theming
    • TextBlock_Uno_UI_Samples_Content_UITests_TextBlockControl_TextBlock_BrushColorChanging_Uno_UI_Samples_Content_UITests_TextBlockControl_TextBlock_BrushColorChanging
    • TextBlock_Uno_UI_Samples_Content_UITests_TextBlockControl_TextBlock_Special_Character_Uno_UI_Samples_Content_UITests_TextBlockControl_TextBlock_Special_Character
    • ListView_ListView_OwnContainer_Virtualized_UITests_Shared_Windows_UI_Xaml_Controls_ListView_OwnContainer_Virtualized
    • ListView_ListView_Padding_All_Sides_SamplesApp_Windows_UI_Xaml_Controls_ListView_ListView_Padding_All_Sides
    • MUX_UITests_Shared_Microsoft_UI_Xaml_Controls_TreeViewTests_TreeViewPage_UITests_Shared_Microsoft_UI_Xaml_Controls_TreeViewTests_TreeViewPage
    • Transform_Basics_UITests_Shared_Windows_UI_Xaml_Media_Transform_Basics
    • MUX_TwoPaneView_UITests_Shared_Microsoft_UI_Xaml_Controls_TwoPaneViewTests_TwoPaneViewPage
    • Image_UITests_Windows_UI_Xaml_Controls_ImageTests_ImageAlignment2541_UITests_Windows_UI_Xaml_Controls_ImageTests_ImageAlignment2541
    • ListView_ListViewSelectedItems_SamplesApp_Windows_UI_Xaml_Controls_ListView_ListViewSelectedItems
    • Icons_UITests_Microsoft_UI_Xaml_Controls_ImageIconTests_ImageIconPage_UITests_Microsoft_UI_Xaml_Controls_ImageIconTests_ImageIconPage
    • Icons_UITests_Shared_Windows_UI_Xaml_Controls_BitmapIconTests_BitmapIcon_Foreground_UITests_Shared_Windows_UI_Xaml_Controls_BitmapIconTests_BitmapIcon_Foreground
    • SwipeControl_MUXControlsTestApp_SwipeControlPage2_MUXControlsTestApp_SwipeControlPage2
    • TextBlock_UITests_Windows_UI_Xaml_Controls_TextBlockControl_TextBlock_HorizontalTextAlignment_UITests_Windows_UI_Xaml_Controls_TextBlockControl_TextBlock_HorizontalTextAlignment
  • ios: 12 changed over 267

    🚨🚨 Comparison Details (first 20) 🚨🚨
    • Check_ListView_Swallows_Measure_UITests_Shared_Windows_UI_Xaml_Controls_ListView_ListView_With_ListViews_Count_Measure
    • ListView_ListViewWithHeader_InitializesTest_SamplesApp_Windows_UI_Xaml_Controls_ListView_HorizontalListViewGrouped
    • When_SingleSelectionWithoutItemClick_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
    • ProgressRing_Visibility_Collapsed_UITests_Windows_UI_Xaml_Controls_ProgressRing_WindowsProgressRing_GH1220
    • ProgressRing_IsEnabled_Running_UITests_Windows_UI_Xaml_Controls_ProgressRing_WindowsProgressRing_GH1220
    • ListView_SelectedItems_SamplesApp_Windows_UI_Xaml_Controls_ListView_ListViewSelectedItems
    • TextBox_UpdatedBinding_On_OneWay_Mode_UITests_Windows_UI_Xaml_Controls_TextBox_TextBox_Bindings
    • When_NoSelectionWithItemClick_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
    • When_MultipleSelectionWithoutItemClick_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
    • When_ExtendedSelectionWithoutItemClick_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
    • When_NoSelection_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
    • When_SingleSelectionWithItemClick_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
  • ios-Snap: 42 changed over 962

    🚨🚨 Comparison Details (first 20) 🚨🚨
    • Brushes_ImageBrushWithRotateTransform_Uno_UI_Samples_UITests_ImageBrushTestControl_ImageBrushWithRotateTransform
    • Default_UITests_Windows_UI_Xaml_Controls_TextBox_TextBox_CornerRadius_UITests_Windows_UI_Xaml_Controls_TextBox_TextBox_CornerRadius
    • ListView_HorizontalListView_Padding_SamplesApp_Windows_UI_Xaml_Controls_ListView_HorizontalListView_Padding
    • ListView_ListView_Image_SamplesApp_Windows_UI_Xaml_Controls_ListView_ListView_Image
    • TextBlock_TextBlock_FixedWidth_With_DataBound_Run_Uno_UI_Samples_Content_UITests_TextBlockControl_TextBlock_FixedWidth_With_DataBound_Run
    • ColorPicker_ColorPickerSample_UITests_Microsoft_UI_Xaml_Controls_ColorPickerTests_ColorPickerSample
    • Focus_UITests_Windows_UI_Xaml_FocusTests_Focus_FocusCycle_UITests_Windows_UI_Xaml_FocusTests_Focus_FocusCycle
    • Image_UITests_Windows_UI_Xaml_Controls_ImageTests_Image_Formats_UITests_Windows_UI_Xaml_Controls_ImageTests_Image_Formats
    • Grid_CenteredGridinGridwiththreefixedsizechildren_Uno_UI_Samples_Content_UITests_GridTestsControl_CenteredGridinGridwiththreefixedsizechildren
    • Image_UITests_Shared_Windows_UI_Xaml_Controls_ImageTests_Image_Stretch_Alignment_SizeOnControl_UITests_Shared_Windows_UI_Xaml_Controls_ImageTests_Image_Stretch_Alignment_SizeOnControl
    • NavigationView_MUXControlsTestApp_NavigationViewCustomThemeResourcesPage_MUXControlsTestApp_NavigationViewCustomThemeResourcesPage
    • NavigationView_MUXControlsTestApp_NavigationViewIsPaneOpenPage_MUXControlsTestApp_NavigationViewIsPaneOpenPage
    • Icons_UITests_Microsoft_UI_Xaml_Controls_ImageIconTests_ImageIconPage_UITests_Microsoft_UI_Xaml_Controls_ImageIconTests_ImageIconPage
    • Brushes_PanelImageBrush_Uno_UI_Samples_UITests_ImageBrushTestControl_PanelImageBrush
    • Brushes_ImageBrushStretch_Uno_UI_Samples_UITests_ImageBrushTestControl_ImageBrushStretch
    • Grid_Grid_DataBound_ColumnRow_Definitions_Uno_UI_Samples_Content_UITests_GridTestsControl_Grid_DataBound_ColumnRow_Definitions
    • WebView_UITests_Microsoft_UI_Xaml_Controls_WebView2Tests_WebView2_NavigationProperties_UITests_Microsoft_UI_Xaml_Controls_WebView2Tests_WebView2_NavigationProperties
    • Default_Uno_UI_Samples_Content_UITests_WebView_WebView_AnchorNavigation_Uno_UI_Samples_Content_UITests_WebView_WebView_AnchorNavigation
    • Image_Uno_UI_Samples_UITests_Image_Image_Stretch_Alignment_Wider_Uno_UI_Samples_UITests_Image_Image_Stretch_Alignment_Wider
    • WebView_WebView2_JavascriptInvoke_SamplesApp_Microsoft_UI_Xaml_Controls_WebView2Tests_WebView2_JavascriptInvoke
  • skia-gtk-screenshots: 61 changed over 2222

    🚨🚨 Comparison Details (first 20) 🚨🚨
    • CalendarView_Theming.png-dark
    • CalendarView_Theming.png
    • TransformToVisual_Translate2d.png-dark
    • TransformToVisual_Translate2d.png
    • Gamepad_Enumeration.png-dark
    • ListViewHeaderUpdate.png-dark
    • ListViewHeaderUpdate.png
    • ExpanderColorValidationPage.png-dark
    • ExpanderColorValidationPage.png
    • Gamepad_Enumeration.png
    • WinUIProgressBarSimple.png-dark
    • WinUIProgressBarSimple.png
    • DropDownButtonPage.png-dark
    • ContentPresenter_NativeEmbedding.png-dark
    • ContentPresenter_NativeEmbedding.png
    • Gamepad_CurrentReading.png-dark
    • Gamepad_CurrentReading.png
    • WinUIExpanderPage.png-dark
    • RepeatButton_Automated.png-dark
    • RepeatButton_Automated.png
  • skia-linux-screenshots: 62 changed over 2222

    🚨🚨 Comparison Details (first 20) 🚨🚨
    • Examples.png
    • BorderImageBrush.png
    • Buttons.png-dark
    • Buttons.png
    • Focus_FocusVisual_Properties.png-dark
    • Focus_FocusVisual_Properties.png
    • ImageBrushInList.png-dark
    • ImageBrushInList.png
    • DisplayInformation.png-dark
    • DisplayInformation.png
    • ImageInStackPanel.png-dark
    • ImageInStackPanel.png
    • BorderImageBrush.png-dark
    • Gamepad_Enumeration.png-dark
    • CalendarView_Theming.png
    • ContentPresenter_NativeEmbedding.png-dark
    • ContentPresenter_NativeEmbedding.png
    • CalendarView_Theming.png-dark
    • ClipboardTests.png-dark
    • ButtonClippingTestsControl.png-dark
  • skia-windows-screenshots: 72 changed over 2222

    🚨🚨 Comparison Details (first 20) 🚨🚨
    • AppWindowPositionAndSize.png
    • AppWindowPositionAndSize.png-dark
    • Focus_FocusVisual_Properties.png-dark
    • Focus_FocusVisual_Properties.png
    • DropDownButtonPage.png-dark
    • DropDownButtonPage.png
    • ImageIconPage.png-dark
    • ImageIconPage.png
    • ImageInStackPanel.png-dark
    • ImageInStackPanel.png
    • BorderImageBrushRelativeTransform.png
    • ButtonClippingTestsControl.png
    • Buttons.png-dark
    • Gamepad_Enumeration.png-dark
    • Gamepad_Enumeration.png
    • Image_UseTargetSize.png-dark
    • Image_UseTargetSize.png
    • ButtonClippingTestsControl.png-dark
    • CalendarView_Theming.png
    • Examples.png
  • wasm: 564 changed over 1044

    🚨🚨 Comparison Details (first 20) 🚨🚨
    • GenericApp.Views.Content.UITests.ContentControlTestsControl.ContentControl_UnsetContent
    • GenericApp.Views.Samples.Shared.Content.UITests.GridViewGrouped
    • MUXControlsTestApp.HierarchicalNavigationViewMarkup
    • MUXControlsTestApp.NavigationViewMenuItemStretchPage
    • MUXControlsTestApp.PipsPagerPage
    • SamplesApp.Wasm.Windows_UI_Xaml_Controls.ComboBox.ComboBox_With_ItemContainerStyle
    • SamplesApp.Windows_UI_Xaml.Clipping.Transform_Ellipse_in_two_grids
    • SamplesApp.Windows_UI_Xaml.Clipping.UIElementClipping
    • SamplesApp.Windows_UI_Xaml_Controls.ListView.ListViewGroupedLarge
    • SamplesApp.Windows_UI_Xaml_Controls.ListView.ListViewGroupedLargeLegacy
    • SamplesApp.Windows_UI_Xaml_Shapes.PathTestsControl.PathVerticalOffsetAdjustable
    • SamplesApp.Windows_UI_Xaml_Shapes.PathTestsControl.PathVerticalOffsetII
    • UITests.Microsoft_UI_Xaml_Controls.AnimatedIconTests.AnimatedIconPage
    • UITests.Microsoft_UI_Xaml_Controls.WebView2Tests.WebView2_ExecuteScriptAsync
    • UITests.Microsoft_UI_Xaml_Controls.WebView2Tests.WebView2_NavigationProperties
    • UITests.Shared.MessageDialogTests.MessageDialogTest
    • UITests.Shared.Windows_UI_Input.VisualStatesTests.TextBox_VisualStates
    • UITests.Shared.Windows_UI_StartScreen.JumpListTests
    • UITests.Shared.Windows_UI_Xaml_Controls.Flyout.Flyout_Content_ThemeResource
    • UITests.Shared.Windows_UI_Xaml_Controls.MenuFlyoutTests.MenuFlyout_IosNative
  • wasm-automated-net9.0-UWP-Default-automated: 28 changed over 1946

    🚨🚨 Comparison Details (first 20) 🚨🚨
    • Default_StrokeThickness_MyPolyline
    • ListView_ListViewSelectedItems_SamplesApp_Windows_UI_Xaml_Controls_ListView_ListViewSelectedItems
    • Default_StrokeThickness_MyEllipse
    • Automation_UITests_Shared_Windows_UI_Xaml_Automation_AutomationProperties_Name_UITests_Shared_Windows_UI_Xaml_Automation_AutomationProperties_Name
    • Expander_WinUIExpanderPage_UITests_Shared_Microsoft_UI_Xaml_Controls_ExpanderTests_WinUIExpanderPage
    • ListView_ListView_With_ListViews_Count_Measure_UITests_Shared_Windows_UI_Xaml_Controls_ListView_ListView_With_ListViews_Count_Measure
    • Brushes_BorderImageBrush_Uno_UI_Samples_UITests_ImageBrushTestControl_BorderImageBrush
    • Default_SamplesApp_Wasm_Windows_UI_Xaml_Controls_ListView_ListView_IsSelected_SamplesApp_Wasm_Windows_UI_Xaml_Controls_ListView_ListView_IsSelected
    • Default_StrokeThickness_MyRect
    • Default_Uno_UI_Samples_Content_UITests_WebView_WebView_AnchorNavigation_Uno_UI_Samples_Content_UITests_WebView_WebView_AnchorNavigation
    • MediaPlayerElement_Using_ogg_UITests_Shared_Windows_UI_Xaml_Controls_MediaPlayerElement_MediaPlayerElement_Ogg_Extension
    • ListView_SelectedItems_SamplesApp_Windows_UI_Xaml_Controls_ListView_ListViewSelectedItems
    • Pickers_UITests_Windows_UI_Xaml_Controls_CalendarView_CalendarView_Theming_UITests_Windows_UI_Xaml_Controls_CalendarView_CalendarView_Theming
    • SequentialAnimations_SamplesApp_Windows_UI_Xaml_Media_Animation_SequentialAnimationsPage
    • Validate_Offscreen_Shapes_UITests_Windows_UI_Xaml_Shapes_Offscreen_Shapes
    • When_NoSelection_Then_PointersEvents_UITests_Windows_UI_Xaml_Controls_ListView_ListView_Selection_Pointers
    • When_Theme_Changed_No_Crash_UITests_Windows_UI_Xaml_Controls_CalendarView_CalendarView_Theming
    • Windows_Media_MediaPlayer_UITests_Windows_Media_MediaPlayerTests
    • MediaPlayerElement_Mini_player_UITests_Shared_Windows_UI_Xaml_Controls_MediaPlayerElement_MediaPlayerElement_Minimal
    • MediaPlayerElement_Sources_UITests_Shared_Windows_UI_Xaml_Controls_MediaPlayerElement_MediaPlayerElement_Sources
  • wasm-automated-net9.0-UWP-RuntimeTests-0: 0 changed over 1

  • wasm-automated-net9.0-UWP-RuntimeTests-1: 0 changed over 1

  • wasm-automated-net9.0-UWP-RuntimeTests-2: 0 changed over 1

  • wasm-automated-net9.0-WinUI-Benchmarks-automated: 0 changed over 1

  • wasm-automated-net9.0-WinUI-RuntimeTests-0: 0 changed over 1

  • wasm-automated-net9.0-WinUI-RuntimeTests-1: 0 changed over 1

  • wasm-automated-net9.0-WinUI-RuntimeTests-2: 0 changed over 1

@spouliot spouliot merged commit a029477 into master Nov 6, 2024
108 checks passed
@spouliot spouliot deleted the dev/spouliot/gh16399 branch November 6, 2024 05:23
jeromelaban added a commit that referenced this pull request Nov 6, 2024
…5.5/pr-18688

fix(macOS): Prevent pointer over event originating from other window (backport #18688)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Skia macOS] Pointer over event originating from other window
4 participants