diff options
author | David Heinemeier Hansson <david@loudthinking.com> | 2005-07-02 06:20:05 +0000 |
---|---|---|
committer | David Heinemeier Hansson <david@loudthinking.com> | 2005-07-02 06:20:05 +0000 |
commit | 2f61c431fa3beecb532c0c58c83e47f9759e64a5 (patch) | |
tree | 156e4c226aa529b0deff3564d2b28fa10223e3d9 /actionpack/lib/action_view/helpers/javascripts/dragdrop.js | |
parent | 6d64bbcc56bb2c1862ef4e6ef63db70f87b7bbe6 (diff) | |
download | rails-2f61c431fa3beecb532c0c58c83e47f9759e64a5.tar.gz rails-2f61c431fa3beecb532c0c58c83e47f9759e64a5.tar.bz2 rails-2f61c431fa3beecb532c0c58c83e47f9759e64a5.zip |
Added evaluation of <SCRIPT> blocks in content returned to Ajax calls #1577 [Thomas Fuchs/court3nay]
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1597 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
Diffstat (limited to 'actionpack/lib/action_view/helpers/javascripts/dragdrop.js')
-rw-r--r-- | actionpack/lib/action_view/helpers/javascripts/dragdrop.js | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/actionpack/lib/action_view/helpers/javascripts/dragdrop.js b/actionpack/lib/action_view/helpers/javascripts/dragdrop.js index 78f82bcd23..20432a3c88 100644 --- a/actionpack/lib/action_view/helpers/javascripts/dragdrop.js +++ b/actionpack/lib/action_view/helpers/javascripts/dragdrop.js @@ -111,7 +111,6 @@ Element.Class = { var Droppables = { drops: false, - include_scroll_offsets: false, add: function(element) { var element = $(element); @@ -180,7 +179,7 @@ var Droppables = { if(!this.drops) return; var pX = Event.pointerX(event); var pY = Event.pointerY(event); - if(this.include_scroll_offsets) Position.prepare(); + Position.prepare(); var i = this.drops.length-1; do { var drop = this.drops[i]; @@ -200,7 +199,7 @@ var Droppables = { if(!this.drops) return; var pX = Event.pointerX(event); var pY = Event.pointerY(event); - if(this.include_scroll_offsets) Position.prepare(); + Position.prepare(); var i = this.drops.length-1; do { var drop = this.drops[i]; @@ -251,6 +250,10 @@ Draggable.prototype = { this.element.drag = this; this.handle = options.handle ? $(options.handle) : this.element; + // fix IE + if(!this.element.style.position) + this.element.style.position = 'relative'; + this.offsetX = 0; this.offsetY = 0; this.originalLeft = this.currentLeft(); |