aboutsummaryrefslogtreecommitdiffstats
path: root/railties/html/javascripts/dragdrop.js
diff options
context:
space:
mode:
authorThomas Fuchs <thomas@fesch.at>2005-12-25 18:23:25 +0000
committerThomas Fuchs <thomas@fesch.at>2005-12-25 18:23:25 +0000
commit1455697ee85b3ad151213e48838e916c3cf96b0c (patch)
tree7f13f58a140121c8f3d83b0672161399d1315af4 /railties/html/javascripts/dragdrop.js
parentcfb0babec348a5543ae4c4a8c2c5e4438644429e (diff)
downloadrails-1455697ee85b3ad151213e48838e916c3cf96b0c.tar.gz
rails-1455697ee85b3ad151213e48838e916c3cf96b0c.tar.bz2
rails-1455697ee85b3ad151213e48838e916c3cf96b0c.zip
Update to script.aculo.us to 1.5.0 rev. 3343
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3349 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'railties/html/javascripts/dragdrop.js')
-rw-r--r--railties/html/javascripts/dragdrop.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/railties/html/javascripts/dragdrop.js b/railties/html/javascripts/dragdrop.js
index 92d1f73162..818ef5e0ed 100644
--- a/railties/html/javascripts/dragdrop.js
+++ b/railties/html/javascripts/dragdrop.js
@@ -146,6 +146,7 @@ var Draggables = {
if(!this.activeDraggable) return;
this._lastPointer = null;
this.activeDraggable.endDrag(event);
+ this.activeDraggable = null;
},
keyPress: function(event) {
@@ -191,7 +192,7 @@ Draggable.prototype = {
},
reverteffect: function(element, top_offset, left_offset) {
var dur = Math.sqrt(Math.abs(top_offset^2)+Math.abs(left_offset^2))*0.02;
- element._revert = new Effect.MoveBy(element, -top_offset, -left_offset, {duration:dur});
+ element._revert = new Effect.Move(element, { x: -left_offset, y: -top_offset, duration: dur});
},
endeffect: function(element) {
new Effect.Opacity(element, {duration:0.2, from:0.7, to:1.0});
@@ -227,8 +228,8 @@ Draggable.prototype = {
currentDelta: function() {
return([
- parseInt(this.element.style.left || '0'),
- parseInt(this.element.style.top || '0')]);
+ parseInt(Element.getStyle(this.element,'left') || '0'),
+ parseInt(Element.getStyle(this.element,'top') || '0')]);
},
initDrag: function(event) {