Patch for video.js to prevent mousemove spam #331

Merged
merged 1 commit into from Mar 9, 2014

Conversation

Projects
None yet
4 participants
@download13
Contributor

download13 commented Mar 9, 2014

On certain platforms (including node-webkit on Windows7 64-bit it seems) mousemove events are spammed whether or not the mouse has actually moved. This prevents the video player UI from being hidden since it always thinks the user is moving the mouse.

This is a patch for video.js that filters out the false mousemove events. I've already sent it as a PR to the video.js people, but until they make a decision this is a stopgap measure.

I'm not sure what causes it. Someone on StackExchange said that Webkit firing phantom mousemove events might have something to do with preventing a machine going into standby. The odd thing is that it only happens when the cursor is positioned over certain content. For example, events are not fired if the cursor is positioned over the #header element when selecting a movie, but almost anywhere else will result in a constant stream of mousemoves.

The point is, this seems to fix it for now. Ideally, it should be fixed in Webkit (assuming that's where the problem is from).

Patch for video.js to prevent mousemove spam
On certain platforms (including node-webkit on Windows7 64-bit it seems) mousemove events are spammed whether or not the mouse has actually moved. This prevents the video player UI from being hidden since it always thinks the user is moving the mouse.

This is a patch for video.js that filter out the false mousemove events. I've already sent it as a PR to the video.js people, but until they make a decision this is a stopgap measure.

I'm not sure what causes it. Someone on StackExchange said that Webkit firing phantom mousemove events might have something to do with preventing a machine going into standby. The odd thing is that it only happens when the cursor is positioned over certain content. For example, events are not fired if the cursor is positioned over the #header element when selecting a movie, but almost anywhere else will result in a constant stream of mousemoves.

The point is, this seems to fix it for now. Ideally, it should be fixed in Webkit (assuming that's where the problem is from).

Patineta added a commit that referenced this pull request Mar 9, 2014

Merge pull request #331 from download13/master
Patch for video.js to prevent mousemove spam

@Patineta Patineta merged commit 54e0759 into popcorn-time:master Mar 9, 2014

@Patineta

This comment has been minimized.

Show comment Hide comment
@Patineta

Patineta Mar 9, 2014

Contributor

That's a great find! We got one report of this previously, but as it seems to happen on very specific platforms and we couldn't replicate it, this should help with that. Thanks for the fix!

Contributor

Patineta commented Mar 9, 2014

That's a great find! We got one report of this previously, but as it seems to happen on very specific platforms and we couldn't replicate it, this should help with that. Thanks for the fix!

@h3ku

This comment has been minimized.

Show comment Hide comment
@h3ku

h3ku Mar 10, 2014

Thanks for this, not big problem, but make this little bit perfect.

h3ku commented on 0f368b1 Mar 10, 2014

Thanks for this, not big problem, but make this little bit perfect.

This comment has been minimized.

Show comment Hide comment
@dimartiro

dimartiro Mar 10, 2014

Thanks!! i was waiting for this!

Thanks!! i was waiting for this!

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