Skip to content
This repository has been archived by the owner on Feb 11, 2021. It is now read-only.

pointerdown only fires once in Firefox v0.4.0 #242

Closed
ademup opened this issue Nov 9, 2015 · 9 comments
Closed

pointerdown only fires once in Firefox v0.4.0 #242

ademup opened this issue Nov 9, 2015 · 9 comments
Milestone

Comments

@ademup
Copy link

ademup commented Nov 9, 2015

Problem: v 0.4.0 Firefox only fires "pointerdown" once, not allowing subsequent pointer downs.
v0.3.0 does not have the same problem.

Steps:

  1. Went here: http://jsbin.com/bojumofowa/1/edit?html,css,js,output
  2. Change to /pep/0.4.0/pep.js
  3. Change event to on("pointerdown")
  4. Click in canvas area, only one pixel shows. All subsequent clicks are ignored.

I'm using Firefox 42.0 on Ubuntu.

@bethge
Copy link
Contributor

bethge commented Nov 10, 2015

Does this jsbin look like the one you are describing: http://jsbin.com/muwovegowo/edit?html,css,js,output ?

I tried it in FF 37.0.2, FF 42.0 and FF 45.0a1f (Nightly) on OS X and repeated clicks do show up.

Is your experience the same with other browsers?

@tf
Copy link

tf commented Nov 10, 2015

@bethge your fiddle does not work for me on Firefox 38 under Ubuntu. If I change the script tag to 0.3.0 it works.

@bethge
Copy link
Contributor

bethge commented Nov 10, 2015

Indeed! I got my hands on an Ubuntu 14.04 LTS with FF 39 and the fiddle does not work with 0.4.0.

@ademup
Copy link
Author

ademup commented Nov 10, 2015

@bethge - that is correct. It also does not work on FF 41.0.2 on Ubuntu 15.04. If I change your jsbin to pep/0.3.0/ it works just fine in both 14.04 and 15.04. Both pep versions work in Chrome on both 15.04 and 14.04.

@bethge
Copy link
Contributor

bethge commented Nov 11, 2015

I believe no second pointerdown is triggered due to no pointerup being triggered from the first pointerdown, leaving the pointermap in disarray.

In FF on Ubuntu mouseup for a left-click has the properties buttons: 1 and button: 0, while most other browser have the properties buttons: 0 and button: 0. With PEP 0.4.0, the buttons property, if available, is used for pointerup checking: https://github.com/jquery/PEP/blob/master/src/mouse.js#L107 .

@scottgonzalez
Copy link
Contributor

@mbrubeck Sounds like this might be a web compat issue. Are you aware of this behavior?

@mbrubeck
Copy link

I think this may be https://bugzilla.mozilla.org/show_bug.cgi?id=1223366

@scottgonzalez
Copy link
Contributor

Indeed it is. I don't believe Sebastian's comment is correct. The spec says "During any mouse events, buttons must be used to indicate which combination of mouse buttons are currently being pressed, expressed as a bitmask." and the button is obviously not currently being pressed at the point that mouseup is fired.

@mbrubeck
Copy link

I submitted a patch for the Firefox bug. The bug fix should be included in Firefox 45, which will be released in March 2016. PR #243 looks like a good workaround until then.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants