From 53e2f6cea55a2702bde66cef3eb49686a1cbb02b Mon Sep 17 00:00:00 2001 From: David Date: Wed, 25 Sep 2024 13:24:05 -0400 Subject: [PATCH 01/13] fix: Restore inertia --- src/Uno.UI/UI/Input/GestureRecognizer.cs | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/src/Uno.UI/UI/Input/GestureRecognizer.cs b/src/Uno.UI/UI/Input/GestureRecognizer.cs index b714182873c2..e019af849a51 100644 --- a/src/Uno.UI/UI/Input/GestureRecognizer.cs +++ b/src/Uno.UI/UI/Input/GestureRecognizer.cs @@ -157,14 +157,7 @@ internal void ProcessUpEvent(PointerPoint value, bool isRelevant) _log.Debug($"{Owner} Received a 'Up' for a pointer which was not considered as down. Ignoring event."); } - if (isRelevant) - { - _manipulation?.Remove(value); - } - else - { - _manipulation?.Complete(); - } + _manipulation?.Remove(value); } #if IS_UNIT_TESTS From fbf039b60a37c24e96370f321f641aba73720579 Mon Sep 17 00:00:00 2001 From: David Date: Thu, 26 Sep 2024 14:08:32 -0400 Subject: [PATCH 02/13] test: Add test for inertia processor --- .../Manipulation_Inertia.xaml | 32 ++--- .../Manipulation_Inertia.xaml.cs | 62 +--------- .../Given_GestureRecognizer.cs | 61 ++++++++++ .../TestPages/Manipulation_Inertia.xaml | 41 +++++++ .../TestPages/Manipulation_Inertia.xaml.cs | 113 ++++++++++++++++++ 5 files changed, 225 insertions(+), 84 deletions(-) create mode 100644 src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml_Input/Given_GestureRecognizer.cs create mode 100644 src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml_Input/TestPages/Manipulation_Inertia.xaml create mode 100644 src/Uno.UI.RuntimeTests/Tests/Windows_UI_Xaml_Input/TestPages/Manipulation_Inertia.xaml.cs diff --git a/src/SamplesApp/UITests.Shared/Windows_UI_Input/GestureRecognizerTests/Manipulation_Inertia.xaml b/src/SamplesApp/UITests.Shared/Windows_UI_Input/GestureRecognizerTests/Manipulation_Inertia.xaml index f095f60f61c9..f3e3aed2fe32 100644 --- a/src/SamplesApp/UITests.Shared/Windows_UI_Input/GestureRecognizerTests/Manipulation_Inertia.xaml +++ b/src/SamplesApp/UITests.Shared/Windows_UI_Input/GestureRecognizerTests/Manipulation_Inertia.xaml @@ -1,26 +1,12 @@  + x:Class="UITests.Windows_UI_Input.GestureRecognizerTests.Manipulation_Inertia" + xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" + xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" + xmlns:runtimeTests="using:RuntimeTests.Tests.Windows_UI_Xaml_Input.TestPages" + xmlns:d="http://schemas.microsoft.com/expression/blend/2008" + xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" + mc:Ignorable="d" + Background="{ThemeResource ApplicationPageBackgroundThemeBrush}"> - - - - -