Skip to content

Commit

Permalink
fix(event): fix init event job->chrome bug for getMovementDeltaWhenPo…
Browse files Browse the repository at this point in the history
…interLocked: use skip(2) instead of skip(1)

(refer to d60b64f)
  • Loading branch information
yyc-git committed May 24, 2019
1 parent 4d89c8e commit 6eb7a9d
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
2 changes: 1 addition & 1 deletion src/core/job/init/InitEventJob.re
Original file line number Diff line number Diff line change
Expand Up @@ -470,7 +470,7 @@ module DomEvent = {
fix chrome bug for getMovementDeltaWhenPointerLocked:
the first movementDelta->x >100!
*/
|> WonderBsMost.Most.skip(1)
|> WonderBsMost.Most.skip(2)
|> WonderBsMost.Most.until(
_fromPointDomEvent("mouseup", engineState)
|> WonderBsMost.Most.tap(event =>
Expand Down
1 change: 1 addition & 0 deletions test/integration/job/tool/EventTool.re
Original file line number Diff line number Diff line change
Expand Up @@ -279,4 +279,5 @@ let buildBodyTarget = () => {"tagName": "BODY"};
let triggerFirstMouseDragOverEvent = mouseEvent => {
triggerDomEvent("mousemove", getBody(), mouseEvent);
triggerDomEvent("mousemove", getBody(), mouseEvent);
triggerDomEvent("mousemove", getBody(), mouseEvent);
};

0 comments on commit 6eb7a9d

Please sign in to comment.