From 4d913f33a88ea1e92134d29786709d7a1e3c8ef4 Mon Sep 17 00:00:00 2001 From: Simon Jackson Date: Mon, 19 Feb 2018 15:23:38 +0000 Subject: [PATCH] HorizontalScrollSnap.cs updated to match VerticalScrollSnap - Resolves #213 --- Scripts/Layout/HorizontalScrollSnap.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Scripts/Layout/HorizontalScrollSnap.cs b/Scripts/Layout/HorizontalScrollSnap.cs index 43b2c0d..d3a0883 100644 --- a/Scripts/Layout/HorizontalScrollSnap.cs +++ b/Scripts/Layout/HorizontalScrollSnap.cs @@ -49,7 +49,7 @@ namespace UnityEngine.UI.Extensions //If the container is moving check if it needs to settle on a page if (!_pointerDown) { - if (_scroll_rect.velocity.x > 0.01 || _scroll_rect.velocity.x < 0.01) + if (_scroll_rect.velocity.x > 0.01 || _scroll_rect.velocity.x < -0.01) { //if the pointer is released and is moving slower than the threshold, then just land on a page if (IsRectMovingSlowerThanThreshold(0))