aboutsummaryrefslogtreecommitdiff
path: root/src/client/views/animationtimeline/TimelineOverview.tsx
diff options
context:
space:
mode:
authorandrewdkim <adkim414@gmail.com>2019-08-14 16:52:19 -0400
committerandrewdkim <adkim414@gmail.com>2019-08-14 16:52:19 -0400
commite507271488fe4c8dcb548dc766ab131fa84f4437 (patch)
treefae2ecb5a84a9ff2cfe6f3c1d97556c217d89a15 /src/client/views/animationtimeline/TimelineOverview.tsx
parenta8b5ba65bafd35b2497753375a3e8aa8d37dad4d (diff)
ink fix and overview fix
Diffstat (limited to 'src/client/views/animationtimeline/TimelineOverview.tsx')
-rw-r--r--src/client/views/animationtimeline/TimelineOverview.tsx6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/client/views/animationtimeline/TimelineOverview.tsx b/src/client/views/animationtimeline/TimelineOverview.tsx
index 4fdf1381e..38b823cbc 100644
--- a/src/client/views/animationtimeline/TimelineOverview.tsx
+++ b/src/client/views/animationtimeline/TimelineOverview.tsx
@@ -25,6 +25,8 @@ export class TimelineOverview extends React.Component<TimelineOverviewProps>{
@action
onPointerDown = (e:React.PointerEvent) => {
+ e.stopPropagation();
+ e.preventDefault();
document.removeEventListener("pointermove", this.onPanX);
document.removeEventListener("pointerup", this.onPointerUp);
document.addEventListener("pointermove", this.onPanX);
@@ -33,12 +35,16 @@ export class TimelineOverview extends React.Component<TimelineOverviewProps>{
@action
onPanX = (e: PointerEvent) => {
+ e.stopPropagation();
+ e.preventDefault();
let movX = (this.props.visibleStart / this.props.totalLength)* (this.DEFAULT_WIDTH * this.props.scale) + e.movementX;
this.props.movePanX((movX / (this.DEFAULT_WIDTH * this.props.scale)) * this.props.totalLength);
}
@action
onPointerUp = (e: PointerEvent) => {
+ e.stopPropagation();
+ e.preventDefault();
document.removeEventListener("pointermove", this.onPanX);
document.removeEventListener("pointerup", this.onPointerUp);
}