void OnScrollAreaDragging(Point newDraggingPoint)
        {
            if (IsDragging == false)
            {
                return;
            }
            DraggingPoint = newDraggingPoint;
            refToViewModel.DraggingPoint = DraggingPoint;
            var deltaPointForScrollToHorizontalOffset = DraggingPoint - DraggingPointPreviousForScrollToHorizontalOffset;

            ContentHorizontalOffsetDesired += deltaPointForScrollToHorizontalOffset.X;
            ScrollAreaScrollViewer.ScrollToHorizontalOffset(-ContentHorizontalOffsetDesired);
            DraggingPointPreviousForScrollToHorizontalOffset = DraggingPoint;
            UpdateDraggingVelocity();
        }
 void OnScrollAreaDispatcherTimerUpdateScrolling()
 {
     if (IsDragging)
     {
         UpdateDraggingVelocity();
     }
     else
     {
         FlickingCursorVelocity          = FlickingCursorVelocityEmaAlphaInDeltaTime * FlickingCursorVelocity;
         ContentHorizontalOffsetDesired += FlickingCursorVelocity.X * TimerIntervalTotalSeconds;
         ScrollAreaScrollViewer.ScrollToHorizontalOffset(-ContentHorizontalOffsetDesired);
         if (Math.Abs(FlickingCursorVelocity.X) < 1e-5)
         {
             DragVelocityEstimationAndFlickScrollingDispatcherTimer.Stop();
         }
     }
 }
        void InitializeScrollArea()
        {
            DragVelocityEstimationAndFlickScrollingDispatcherTimer.Interval = TimeSpan.FromSeconds(TimerIntervalTotalSeconds);
            UpdateFlickingCursorVelocityEmaAlphaInDeltaTime();

            ScrollAreaListView.SizeChanged += (sender, e) =>
            {
                ContentHorizontalOffsetDesired = -ScrollAreaListView.ActualWidth / 2;
                ScrollAreaScrollViewer.ScrollToHorizontalOffset(-ContentHorizontalOffsetDesired);
            };

            // TODO: In Windows 7, flick gesture is unavailable in the first execution of this application.
            if (ApplicationCommonSettings.IsToEmulateReportByActualMouseRawInputToDebugViews)
            {
                ScrollAreaListView.MouseLeftButtonDown += (sender, e) => { OnScrollAreaDragStarted(e.GetPosition(ScrollAreaScrollViewer)); };
                ScrollAreaListView.MouseMove           += (sender, e) => { OnScrollAreaDragging(e.GetPosition(ScrollAreaScrollViewer)); };
                ScrollAreaListView.MouseLeftButtonUp   += (sender, e) => { if (IsDragging)
                                                                           {
                                                                               OnScrollAreaDragEndedFlickStarted();
                                                                           }
                };
                ScrollAreaListView.MouseLeave += (sender, e) => { if (IsDragging)
                                                                  {
                                                                      OnScrollAreaDragEndedFlickStarted();
                                                                  }
                };
            }
            else
            {
                ScrollAreaListView.TouchDown += (sender, e) => { OnScrollAreaDragStarted(e.GetTouchPoint(ScrollAreaScrollViewer).Position); };
                ScrollAreaListView.TouchMove += (sender, e) => { OnScrollAreaDragging(e.GetTouchPoint(ScrollAreaScrollViewer).Position); };
                ScrollAreaListView.TouchUp   += (sender, e) => { if (IsDragging)
                                                                 {
                                                                     OnScrollAreaDragEndedFlickStarted();
                                                                 }
                };
                ScrollAreaListView.TouchLeave += (sender, e) => { if (IsDragging)
                                                                  {
                                                                      OnScrollAreaDragEndedFlickStarted();
                                                                  }
                };
            }

            if (false)
            {
                if (false)
                {
                    ScrollAreaListView.ManipulationStarted         += delegate { Debug.WriteLine("ManipulationStarted"); };
                    ScrollAreaListView.ManipulationDelta           += delegate { Debug.WriteLine("ManipulationDelta"); };
                    ScrollAreaListView.ManipulationInertiaStarting += delegate { Debug.WriteLine("ManipulationInertiaStarting"); };
                }
                ScrollAreaListView.ManipulationStarted         += (sender, e) => { OnScrollAreaDragStarted(e.ManipulationOrigin); };
                ScrollAreaListView.ManipulationDelta           += (sender, e) => { OnScrollAreaDragging(e.ManipulationOrigin); };
                ScrollAreaListView.ManipulationInertiaStarting += (sender, e) => { if (IsDragging)
                                                                                   {
                                                                                       OnScrollAreaDragEndedFlickStarted();
                                                                                   }
                };
            }
            DragVelocityEstimationAndFlickScrollingDispatcherTimer.Tick += (sender, e) => { OnScrollAreaDispatcherTimerUpdateScrolling(); };
        }