Skip to content

Commit

Permalink
Merge pull request #2 from monfera/cqliu1-canvas/help-menu
Browse files Browse the repository at this point in the history
Fix: reintroduce additional call on keyboard event
  • Loading branch information
cqliu1 authored Feb 21, 2019
2 parents 7b2fa27 + daaa871 commit f6b0c13
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -127,6 +127,7 @@ const handleMouseDown = (commit, e, isEditable) => {
export const eventHandlers = {
onMouseDown: props => e => handleMouseDown(props.commit, e, props.isEditable),
onMouseMove: props => e => handleMouseMove(props.commit, e, props.isEditable),
onKeyDown: props => () => props.commit('keyboardEvent'), // dummy event
onWheel: props => e => handleWheel(props.commit, e, props.isEditable),
resetHandler: () => () => resetHandler(),
};
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@ export class WorkpadPage extends PureComponent {
width: PropTypes.number.isRequired,
isEditable: PropTypes.bool.isRequired,
onDoubleClick: PropTypes.func,
onKeyDown: PropTypes.func,
onMouseDown: PropTypes.func,
onMouseMove: PropTypes.func,
onMouseUp: PropTypes.func,
Expand Down Expand Up @@ -70,6 +71,7 @@ export class WorkpadPage extends PureComponent {
width,
isEditable,
onDoubleClick,
onKeyDown,
onMouseDown,
onMouseMove,
onMouseUp,
Expand Down Expand Up @@ -143,6 +145,7 @@ export class WorkpadPage extends PureComponent {
width,
cursor,
}}
onKeyDown={onKeyDown}
onMouseMove={onMouseMove}
onMouseUp={onMouseUp}
onMouseDown={onMouseDown}
Expand Down

0 comments on commit f6b0c13

Please sign in to comment.