12-31-2017 12:12
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


12-31-2017 12:12
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
It seems to me that onmouseup() is fired shortly after onmousedown() even if one's finger remains on the screen (as though the event is emulating a simple click). After onmouseup(), onmousemove() events can continue to occur, which shouldn't happen on a touch-screen device.
This makes drag-and-drop or swipe gestures rather kludgy to implement. It would be useful if onmouseup() fired when one's finger was uplifted.
The relevant documentation is here.
Gondwana Software
Answered! Go to the Best Answer.
Accepted Solutions
01-13-2018 19:33
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

SunsetRunner
01-13-2018 19:33
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
That's a workaround I use. It's pretty crappy but it sort of works. There is definitely a bug in the onmouseup and onmousedown Touch Events where both fire simultaneously regardless of which way you swipe. Hopefully that gets fixed soon.
01-13-2018 19:33
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

SunsetRunner
01-13-2018 19:33
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
var y = 0;
scrollableArea.onmousemove = function(evt) {
if (evt.screenY < y) {
doDownAction();
}
else if (evt.screenY > y) {
doUpAction();
}
y = evt.screenY;
}

01-13-2018 19:33
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

SunsetRunner
01-13-2018 19:33
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
That's a workaround I use. It's pretty crappy but it sort of works. There is definitely a bug in the onmouseup and onmousedown Touch Events where both fire simultaneously regardless of which way you swipe. Hopefully that gets fixed soon.
01-13-2018 20:01
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


01-13-2018 20:01
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
Thanks for the confirmation. For my purposes, I had to use a timeout to see when onmousemove() events stopped happening. This means reduced responsiveness.
Your solution would avoid such unresponsiveness.
Gondwana Software
01-29-2019 12:46
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

01-29-2019 12:46
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Have the same issue and no workaround (so far). I need to kick off setInterval while screen is pressed and clear the interval when it's no longer pressed. Basic stuff, really annoying that it doesn't work

01-29-2019 13:51
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


01-29-2019 13:51
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
From discord:
"orviwan (JonFitbit):something weird, if the rect is fullscreen, there are certain parts where you can touch and the mouseup doesn't trigger immediately, other parts it does"
Orviwan has submitted an official bug report.
Gondwana Software
03-02-2019 20:47
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

03-02-2019 20:47
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
Thanks for posting!
Thought I was doing something wrong till I found this posting. 🙂
07-09-2019 06:57
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post

07-09-2019 06:57
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
Another workaround is to simply use the onClick event in place of the onMouseUp event since in this context they are equivalent.

07-09-2019 10:35
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post


07-09-2019 10:35
- Mark as New
- Bookmark
- Subscribe
- Permalink
- Report this post
- Who Voted for this post?
The next firmware update will have a fix for this issue, and no, I don't have a specific release date yet.
