Skip to content

fix(mouse): preserve held button during movement - #646

Open
sean0407 wants to merge 1 commit into
rubycdp:mainfrom
sean0407:codex/move-preserve-held-button
Open

sean0407 wants to merge 1 commit into
rubycdp:mainfrom
sean0407:codex/move-preserve-held-button

Conversation

@sean0407

Copy link
Copy Markdown

Summary

Mouse#move
  keep the existing buttons bitmask
+ send the pressed button, or "none" while idle
  -> Chrome can recognize drags and emit Input.dragIntercepted

Fixes #635.

Evidence

  • Before: bundle exec rspec spec/mouse_spec.rb:60 failed because Input.dragIntercepted was not emitted.
  • After: bundle exec rspec spec/mouse_spec.rb — 18 examples, 0 failures, 10 pending.
  • After: bundle exec rubocop lib/ferrum/mouse.rb spec/mouse_spec.rb — 2 files inspected, no offenses.
  • Patch policy: 3 text files, 27 changed lines, no binary changes.

Merge Danger

Door: Two-way

Blast Radius: Narrow

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Mouse#move omits button: on mouseMoved, so drags never start

1 participant