Merge pull request #7301 from Rob--W/grab-to-pan-mouse-buttons

Update grab_to_pan.js
This commit is contained in:
Jonas Jenwald 2016-05-08 09:46:32 +02:00
commit 5f59d079e0

View File

@ -1,4 +1,4 @@
/* Copyright 2013 Rob Wu <gwnRob@gmail.com>
/* Copyright 2013 Rob Wu <rob@robwu.nl>
* https://github.com/Rob--W/grab-to-pan.js
*
* Licensed under the Apache License, Version 2.0 (the "License");
@ -215,7 +215,7 @@
// http://www.w3.org/TR/DOM-Level-3-Events/#events-MouseEvent-buttons
// Firefox 15+
// Internet Explorer 10+
return !(event.buttons | 1);
return !(event.buttons & 1);
}
if (isChrome15OrOpera15plus || isSafari6plus) {
// Chrome 14+