mirror of
https://github.com/scratchfoundation/paper.js.git
synced 2025-07-09 11:14:06 -04:00
HitTesting example: Fix dragging of paths and segments.
This commit is contained in:
parent
c197f531a4
commit
469aa18f1a
1 changed files with 3 additions and 4 deletions
|
@ -89,12 +89,11 @@
|
||||||
|
|
||||||
function onMouseDrag(event) {
|
function onMouseDrag(event) {
|
||||||
if (segment) {
|
if (segment) {
|
||||||
segment.point = event.point;
|
segment.point += event.delta;
|
||||||
path.smooth();
|
path.smooth();
|
||||||
}
|
} else if (path) {
|
||||||
|
|
||||||
if (movePath)
|
|
||||||
path.position += event.delta;
|
path.position += event.delta;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
</head>
|
</head>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue