Skip to content

Commit e4ebd53

Browse files
authored
Merge pull request scratchfoundation#5050 from paulkaplan/fix-recording-drag-firefox
Prevent default when dragging trim handles to prevent image drag
2 parents 1259457 + c855152 commit e4ebd53

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

src/containers/audio-trimmer.jsx

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -42,11 +42,15 @@ class AudioTrimmer extends React.Component {
4242
this.containerSize = this.containerElement.getBoundingClientRect().width;
4343
this.trimStartDragRecognizer.start(e);
4444
this.initialTrim = this.props.trimStart;
45+
e.stopPropagation();
46+
e.preventDefault();
4547
}
4648
handleTrimEndMouseDown (e) {
4749
this.containerSize = this.containerElement.getBoundingClientRect().width;
4850
this.trimEndDragRecognizer.start(e);
4951
this.initialTrim = this.props.trimEnd;
52+
e.stopPropagation();
53+
e.preventDefault();
5054
}
5155
storeRef (el) {
5256
this.containerElement = el;

0 commit comments

Comments
 (0)