From 7a8e8a0bd36fa031d7b99fc7968db8e8f914cb1a Mon Sep 17 00:00:00 2001 From: Ano-sys Date: Sun, 23 Mar 2025 00:25:58 +0100 Subject: [PATCH] Added Undo List to hold freshly undid drawn Lines --- ViewModels/ViewModelBase.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/ViewModels/ViewModelBase.cs b/ViewModels/ViewModelBase.cs index 3deef04..02ef101 100644 --- a/ViewModels/ViewModelBase.cs +++ b/ViewModels/ViewModelBase.cs @@ -1,4 +1,5 @@ using System; +using System.Collections.Generic; using System.Collections.ObjectModel; using System.ComponentModel.DataAnnotations; using System.IO; @@ -27,7 +28,8 @@ public class ViewModelBase : ObservableObject public IRelayCommand? CanvasPointerReleasedCommand { get; set; } public ObservableCollection DrawingPoints { get; set; } = new(); public DrawingPoints? DrawingPoint { get; set; } - + protected List UndoDrawingPoints = new(); + protected bool IsDrawing { get; set; } private string _selectedColor = "Black";