From 3879b6fd52395ba47c070b1085d4212f0d376cb4 Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Fri, 1 Feb 2013 16:36:05 +0400 Subject: LoadData early than end --- Juick/Classes/ScrollViewerMonitor.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Juick/Classes/ScrollViewerMonitor.cs') diff --git a/Juick/Classes/ScrollViewerMonitor.cs b/Juick/Classes/ScrollViewerMonitor.cs index a985360..4e96797 100644 --- a/Juick/Classes/ScrollViewerMonitor.cs +++ b/Juick/Classes/ScrollViewerMonitor.cs @@ -1,5 +1,6 @@ using System; using System.Collections.Generic; +using System.Diagnostics; using System.Windows; using System.Windows.Controls; using System.Windows.Data; @@ -46,7 +47,7 @@ namespace Juick.Classes var listener = new DependencyPropertyListener(); listener.Changed += (s, eArgs) => { - var atBottom = scrollViewer.VerticalOffset >= scrollViewer.ScrollableHeight; + var atBottom = scrollViewer.VerticalOffset >= scrollViewer.ScrollableHeight - scrollViewer.ScrollableHeight/3; if (atBottom) { var atEnd = GetAtEndCommand(element); -- cgit v1.2.3