Giter Club home page Giter Club logo

Comments (4)

jakearchibald avatar jakearchibald commented on August 29, 2024 1

Fixed in 472dacc and published as 2.5.2.

The library keeps an eye on move events, and if the left button is no longer down it runs the 'end' steps for that pointer.

from pointer-tracker.

jakearchibald avatar jakearchibald commented on August 29, 2024

Thanks for filing this. I've created a reduced example at https://static-misc-3.glitch.me/pointer-test/ that doesn't use this library.

I'm trying to figure out if I'm missing something, or if this is a browser bug.

from pointer-tracker.

JeroenBakker avatar JeroenBakker commented on August 29, 2024

Some additional findings (in Chrome):

  • I was wrong about having to keep the cursor still during step 2, you can move it before pressing RMB and the bug will still occur.
  • The bug doesn't occur if you wait a little while between pressing and releasing LMB during step 5, I mistook this for having to keep the cursor still, but you can still trigger the bug if you move and release quickly enough.
  • With your reduced example I can now see that Safari doesn't trigger a pointerdown if you click another time after the context menu was closed, which is why the pointer state is successfully recovered in the painting demo.

It seems like the browser doesn't fire any pointer events while the context menu is disappearing.

So if the browser were to trigger a pointercancel for the first click when the context menu opened (no idea how this is specced), there would now be an unmatched pointerup event if you wait a second before releasing LMB in step 5, which would also be a little unexpected.

from pointer-tracker.

jakearchibald avatar jakearchibald commented on August 29, 2024

Filed w3c/pointerevents#407 and w3c/pointerevents#408

from pointer-tracker.

Related Issues (9)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.