diff options
author | Mikel Lindsaar <raasdnil@gmail.com> | 2010-02-08 18:57:00 +1100 |
---|---|---|
committer | José Valim <jose.valim@gmail.com> | 2010-02-08 09:42:40 +0100 |
commit | 17b451898c09f560cef105ea120d8e767256555a (patch) | |
tree | fa03e0f1c864a266c32a7da50f7537d27ebeb363 /railties/lib/generators/rails/app/templates/public/javascripts/dragdrop.js | |
parent | 5fe3dc4bf52eb315310a714c0fc1f627d47428fa (diff) | |
download | rails-17b451898c09f560cef105ea120d8e767256555a.tar.gz rails-17b451898c09f560cef105ea120d8e767256555a.tar.bz2 rails-17b451898c09f560cef105ea120d8e767256555a.zip |
Updating Prototype to 1.6.1 and script.aculo.us to 1.8.3
Signed-off-by: José Valim <jose.valim@gmail.com>
Diffstat (limited to 'railties/lib/generators/rails/app/templates/public/javascripts/dragdrop.js')
-rw-r--r-- | railties/lib/generators/rails/app/templates/public/javascripts/dragdrop.js | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/railties/lib/generators/rails/app/templates/public/javascripts/dragdrop.js b/railties/lib/generators/rails/app/templates/public/javascripts/dragdrop.js index 07229f986f..15c6dbca68 100644 --- a/railties/lib/generators/rails/app/templates/public/javascripts/dragdrop.js +++ b/railties/lib/generators/rails/app/templates/public/javascripts/dragdrop.js @@ -1,5 +1,6 @@ -// Copyright (c) 2005-2008 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) -// (c) 2005-2008 Sammi Williams (http://www.oriontransfer.co.nz, sammi@oriontransfer.co.nz) +// script.aculo.us dragdrop.js v1.8.3, Thu Oct 08 11:23:33 +0200 2009 + +// Copyright (c) 2005-2009 Thomas Fuchs (http://script.aculo.us, http://mir.aculo.us) // // script.aculo.us is freely distributable under the terms of an MIT-style license. // For details, see the script.aculo.us web site: http://script.aculo.us/ @@ -311,7 +312,7 @@ var Draggable = Class.create({ tag_name=='TEXTAREA')) return; var pointer = [Event.pointerX(event), Event.pointerY(event)]; - var pos = Position.cumulativeOffset(this.element); + var pos = this.element.cumulativeOffset(); this.offset = [0,1].map( function(i) { return (pointer[i] - pos[i]) }); Draggables.activate(this); @@ -454,7 +455,7 @@ var Draggable = Class.create({ }, draw: function(point) { - var pos = Position.cumulativeOffset(this.element); + var pos = this.element.cumulativeOffset(); if(this.options.ghosting) { var r = Position.realOffset(this.element); pos[0] += r[0] - Position.deltaX; pos[1] += r[1] - Position.deltaY; @@ -730,7 +731,7 @@ var Sortable = { } // keep reference - this.sortables[element.id] = options; + this.sortables[element.identify()] = options; // for onupdate Draggables.addObserver(new SortableObserver(element, options.onUpdate)); @@ -825,7 +826,7 @@ var Sortable = { hide().addClassName('dropmarker').setStyle({position:'absolute'}); document.getElementsByTagName("body").item(0).appendChild(Sortable._marker); } - var offsets = Position.cumulativeOffset(dropon); + var offsets = dropon.cumulativeOffset(); Sortable._marker.setStyle({left: offsets[0]+'px', top: offsets[1] + 'px'}); if(position=='after') |