Commit e0dd2aeb by Tomas Alabes

v2.1.1

parent 22ddc778
......@@ -26,8 +26,6 @@ define([ "path/to/raphael" ], function( Raphael ) {
At the moment we have 4 milestones:
### v2.1.1
Milestone for bug fixes contributed by the community.
### v2.2.0
Milestone for enhancements from contributors pull requests.
### v2.2.1
......
{
"name": "raphael",
"version": "2.1.0",
"version": "2.1.1",
"description": "JavaScript Vector Library",
"main": "raphael.js",
"scripts": {
......
This source diff could not be displayed because it is too large. You can view the blob instead.
// ┌────────────────────────────────────────────────────────────────────┐ \\
// │ Raphaël 2.1.0 - JavaScript Vector Library │ \\
// │ Raphaël 2.1.1 - JavaScript Vector Library │ \\
// ├────────────────────────────────────────────────────────────────────┤ \\
// │ Copyright © 2008-2012 Dmitry Baranovskiy (http://raphaeljs.com) │ \\
// │ Copyright © 2008-2012 Sencha Labs (http://sencha.com) │ \\
......@@ -3584,11 +3584,25 @@
elproto.drag = function (onmove, onstart, onend, move_scope, start_scope, end_scope) {
function start(e) {
(e.originalEvent || e).preventDefault();
var scrollY = g.doc.documentElement.scrollTop || g.doc.body.scrollTop,
var x = e.clientX,
y = e.clientY,
scrollY = g.doc.documentElement.scrollTop || g.doc.body.scrollTop,
scrollX = g.doc.documentElement.scrollLeft || g.doc.body.scrollLeft;
this._drag.x = e.clientX + scrollX;
this._drag.y = e.clientY + scrollY;
this._drag.id = e.identifier;
if (supportsTouch && e.touches) {
var i = e.touches.length, touch;
while (i--) {
touch = e.touches[i];
this._drag.id = touch.identifier;
if (touch.identifier == this._drag.id) {
x = touch.clientX;
y = touch.clientY;
break;
}
}
}
this._drag.x = x + scrollX;
this._drag.y = y + scrollY;
!drag.length && R.mousemove(dragMove).mouseup(dragUp);
drag.push({el: this, move_scope: move_scope, start_scope: start_scope, end_scope: end_scope});
onstart && eve.on("raphael.drag.start." + this.id, onstart);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment