Skip to content

Commit

Permalink
fix(FEC-12372): [WEB][UI] - [O2CZ] Autoplay_WEB - After seeking to th…
Browse files Browse the repository at this point in the history
…e end of the program, the next program will not start playing automatically

When a user performs a mousedown on the seekbar, and a mouseup on the overlay, and no mousedown event has been fired on the overlay earlier, overlay-action does not detect a drag. This causes the mousedown to toggle the player's play/pause.
The solution was to update the drag detection in isDragging by adding the seekbar drag state.
  • Loading branch information
SivanA-Kaltura committed Jul 20, 2022
1 parent 54d5dcc commit 3e80d7b
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions src/components/overlay-action/overlay-action.js
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,8 @@ const mapStateToProps = state => ({
isMobile: state.shell.isMobile,
guiStyles: state.shell.layoutStyles.gui,
isSmartContainerOpen: state.shell.smartContainerOpen,
fullscreenConfig: state.config.components.fullscreen
fullscreenConfig: state.config.components.fullscreen,
seekbarDraggingActive: state.seekbar.draggingActive
});

/**
Expand Down Expand Up @@ -176,7 +177,9 @@ class OverlayAction extends Component {
clientY: event.clientY || (event.changedTouches && event.changedTouches[0] && event.changedTouches[0].clientY)
};
return (
Math.abs(points.clientX - this._pointerDownPosX) > DRAGGING_THRESHOLD || Math.abs(points.clientY - this._pointerDownPosY) > DRAGGING_THRESHOLD
this.props.seekbarDraggingActive ||
Math.abs(points.clientX - this._pointerDownPosX) > DRAGGING_THRESHOLD ||
Math.abs(points.clientY - this._pointerDownPosY) > DRAGGING_THRESHOLD
);
}

Expand Down

0 comments on commit 3e80d7b

Please sign in to comment.