| 263 | | var instance = $.data(this.element[0], 'droppable'); |
| 264 | | if (instance.options.greedy) { |
| 265 | | this.element.parents('.ui-droppable:eq(0)').each(function() { |
| 266 | | var parent = this; |
| 267 | | $.each($.ui.ddmanager.droppables, function() { |
| 268 | | if (this.element[0] != parent) return; |
| 269 | | this[c] = 0; |
| 270 | | this[c == 'isout' ? 'isover' : 'isout'] = 1; |
| 271 | | this.greedyChild = (c == 'isover' ? 1 : 0); |
| 272 | | this[c == 'isout' ? 'over' : 'out'].call(this, e); |
| 273 | | return false; |
| 274 | | }); |
| 275 | | }); |
| | 263 | var parentInstance; |
| | 264 | if (this.options.greedy) { |
| | 265 | var parent = this.element.parents('.ui-droppable:eq(0)'); |
| | 266 | if (parent.length) { |
| | 267 | parentInstance = $.data(parent[0], 'droppable'); |
| | 268 | parentInstance.greedyChild = (c == 'isover' ? 1 : 0); |
| | 269 | } |
| | 270 | } |
| | 271 | |
| | 272 | // we just moved into a greedy child |
| | 273 | if (parentInstance && c == 'isover') { |
| | 274 | parentInstance['isover'] = 0; |
| | 275 | parentInstance['isout'] = 1; |
| | 276 | parentInstance.out.call(parentInstance, e); |