bug: sync pen drawing and stroke generating

This commit is contained in:
dscyrescotti
2024-05-05 17:46:25 +07:00
parent dc4481e2c4
commit 854c7cd732
9 changed files with 244 additions and 106 deletions
@@ -118,6 +118,14 @@ extension GraphicContext {
self.currentPoint = nil
delegate?.didUpdate.send()
}
func cancelStroke() {
if !strokes.isEmpty {
strokes.removeLast()
}
currentStroke = nil
currentPoint = nil
}
}
extension GraphicContext {