From 40f514f6aba6788a383bef75ec67106907d4a24b Mon Sep 17 00:00:00 2001 From: cldupland Date: Mon, 25 Nov 2019 16:38:20 +0100 Subject: [PATCH] Try to correct drag and drop --- TheGameExtreme/view/MainPage.xaml.cs | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/TheGameExtreme/view/MainPage.xaml.cs b/TheGameExtreme/view/MainPage.xaml.cs index 3b1d81e..e58fde0 100644 --- a/TheGameExtreme/view/MainPage.xaml.cs +++ b/TheGameExtreme/view/MainPage.xaml.cs @@ -142,8 +142,7 @@ namespace TheGameExtreme.view int indexPile = stackCollection.IndexOf(stack); if (played(indexPile, decimal.Parse(bitmap.Value))) { - point = stack.InitialPoint; - bitmap.ProcessTouchEvent(args.Id, TouchActionType.Moved, point); + bitmap.ProcessTouchEvent(args.Id, TouchActionType.Moved, stack.InitialPoint); bitmap.InitialPoint = stackCollection[stackCollection.IndexOf(stack)].InitialPoint; stackCollection[stackCollection.IndexOf(stack)] = bitmap; textCollection.RemoveAt(textCollection.Count - 1); @@ -154,8 +153,7 @@ namespace TheGameExtreme.view } if (!find) { - point = bitmap.InitialPoint; - bitmap.ProcessTouchEvent(args.Id, TouchActionType.Moved, point); + bitmap.ProcessTouchEvent(args.Id, TouchActionType.Moved, bitmap.InitialPoint); } bitmap.ProcessTouchEvent(args.Id, args.Type, point); textDictionary.Remove(args.Id);