From 6ee1441dff9736d39bd848b2059e55d27bf4e8f9 Mon Sep 17 00:00:00 2001 From: Tomasz Krakowiak Date: Mon, 21 Jun 2021 12:38:03 +0200 Subject: [PATCH] Fixing issue with DragEnd --- Plk.Blazor.DragDrop/Dropzone.razor.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Plk.Blazor.DragDrop/Dropzone.razor.cs b/Plk.Blazor.DragDrop/Dropzone.razor.cs index 07965cf..5f287bc 100644 --- a/Plk.Blazor.DragDrop/Dropzone.razor.cs +++ b/Plk.Blazor.DragDrop/Dropzone.razor.cs @@ -48,7 +48,7 @@ private void OnDropItemOnSpacing(int newIndex) } //Operation is finished - DragDropService.Reset(); + if (DragEnd == null) DragDropService.Reset(); OnItemDrop.InvokeAsync(activeItem); } @@ -389,7 +389,7 @@ private void OnDrop() } } - DragDropService.Reset(); + if (DragEnd == null) DragDropService.Reset(); StateHasChanged(); OnItemDrop.InvokeAsync(activeItem); }