Skip to content
Merged
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions maui/src/PullToRefresh/SfPullToRefresh.Android.cs
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,8 @@ bool HandleActionMove(MotionEvent ev, Point currenTouchPoint)
_isChildScrolledVertically = IsChildElementScrolled(PullableContent.GetVisualTreeDescendants().FirstOrDefault(), new Point(ev.RawX / _density, ev.RawY / _density));
}

if (_downY < currenTouchPoint.Y && !_isChildScrolledVertically)
// 998288 - A slight downward movement during a tap is treated as a pull gesture, So add 10px vertical threshold before treating as pull gesture.
if ((currenTouchPoint.Y - this._downY) >= 10 && _downY < currenTouchPoint.Y && !_isChildScrolledVertically)
{
return true;
}
Expand Down Expand Up @@ -134,10 +135,10 @@ void ConfigTouch()
{
if (Handler is not null && Handler.PlatformView is not null)
{
// When the handler is changed without creating a new virtual view, adding a touch listener will skip attaching touch wiring to the native view.
// This is because the TouchDetector will still remain in the VirtualView and will be wired with the old handler and old native view.
this.RemoveTouchListener(this);
this.AddTouchListener(this);
// When the handler is changed without creating a new virtual view, adding a touch listener will skip attaching touch wiring to the native view.
// This is because the TouchDetector will still remain in the VirtualView and will be wired with the old handler and old native view.
this.RemoveTouchListener(this);
this.AddTouchListener(this);
_nativeView = Handler.PlatformView as LayoutViewGroupExt;

if (_nativeView is not null && _nativeView.Resources is not null && _nativeView.Resources.DisplayMetrics is not null)
Expand Down
Loading