diff options
| author | bobzel <zzzman@gmail.com> | 2021-09-28 18:33:45 -0400 |
|---|---|---|
| committer | bobzel <zzzman@gmail.com> | 2021-09-28 18:33:45 -0400 |
| commit | ca018693224f5f7737f0546c4fa5f4d4210a3020 (patch) | |
| tree | 4e4e128c3074c8a7925b39f59fb973a8292efa18 /src/client/views/InkStrokeProperties.ts | |
| parent | 244e06ec9873888dcef3cd08322880d73848fe69 (diff) | |
prevent crashes when ink points are not multiple of 4. deleting ink ctrl point that leaves one bezier segment no longer converts to a line.
Diffstat (limited to 'src/client/views/InkStrokeProperties.ts')
| -rw-r--r-- | src/client/views/InkStrokeProperties.ts | 8 |
1 files changed, 0 insertions, 8 deletions
diff --git a/src/client/views/InkStrokeProperties.ts b/src/client/views/InkStrokeProperties.ts index cfe6ec523..510c5f2dd 100644 --- a/src/client/views/InkStrokeProperties.ts +++ b/src/client/views/InkStrokeProperties.ts @@ -160,14 +160,6 @@ export class InkStrokeProperties { if (last) newPoints.splice(newPoints.length - 3, 2); this._currentPoint = -1; if (newPoints.length < 4) return undefined; - if (newPoints.length === 4) { - const newerPoints: { X: number, Y: number }[] = []; - newerPoints.push({ X: newPoints[0].X, Y: newPoints[0].Y }); - newerPoints.push({ X: newPoints[0].X, Y: newPoints[0].Y }); - newerPoints.push({ X: newPoints[3].X, Y: newPoints[3].Y }); - newerPoints.push({ X: newPoints[3].X, Y: newPoints[3].Y }); - return newerPoints; - } return newPoints; }, true) |
