From 70ed01f05807c63c95f507308c7371b5869f308e Mon Sep 17 00:00:00 2001 From: ARCHI86 Date: Mon, 11 Nov 2024 15:41:20 +0300 Subject: [PATCH] =?UTF-8?q?=D0=94=D0=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- GraphPage.xaml.cs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/GraphPage.xaml.cs b/GraphPage.xaml.cs index 23405e4..fc545af 100644 --- a/GraphPage.xaml.cs +++ b/GraphPage.xaml.cs @@ -17,7 +17,7 @@ namespace NotesDataAnalyst private double _scale = 1.0; private double _initialScale = 1.0; private bool _isNodeBeingMoved = false; - private const double SmoothFactor = 0.2; // Коэффициент сглаживания + private const double SmoothFactor = 0.85; // Коэффициент сглаживания private Point _lastTranslation; public GraphPage() @@ -84,8 +84,7 @@ namespace NotesDataAnalyst { if (e.StatusType == GestureStatus.Started) { - _initialPanPosition = new Point(canvasView.TranslationX, canvasView.TranslationY); - _lastTranslation = _initialPanPosition; + _initialPanPosition = new Point(canvasView.TranslationX - e.TotalX, canvasView.TranslationY - e.TotalY); } else if (e.StatusType == GestureStatus.Running) {