{I" class:ETI"ProcessedAsset;FI"logical_path;TI"jquery-ui/droppable.js;FI" pathname;TI"/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/droppable.js;FI"content_type;TI"application/javascript;TI" mtime;Tl+= reference ) && ( x < ( reference + size ) ); } return function( draggable, droppable, toleranceMode ) { if ( !droppable.offset ) { return false; } var draggableLeft, draggableTop, x1 = ( draggable.positionAbs || draggable.position.absolute ).left, y1 = ( draggable.positionAbs || draggable.position.absolute ).top, x2 = x1 + draggable.helperProportions.width, y2 = y1 + draggable.helperProportions.height, l = droppable.offset.left, t = droppable.offset.top, r = l + droppable.proportions().width, b = t + droppable.proportions().height; switch ( toleranceMode ) { case "fit": return ( l <= x1 && x2 <= r && t <= y1 && y2 <= b ); case "intersect": return ( l < x1 + ( draggable.helperProportions.width / 2 ) && // Right Half x2 - ( draggable.helperProportions.width / 2 ) < r && // Left Half t < y1 + ( draggable.helperProportions.height / 2 ) && // Bottom Half y2 - ( draggable.helperProportions.height / 2 ) < b ); // Top Half case "pointer": draggableLeft = ( ( draggable.positionAbs || draggable.position.absolute ).left + ( draggable.clickOffset || draggable.offset.click ).left ); draggableTop = ( ( draggable.positionAbs || draggable.position.absolute ).top + ( draggable.clickOffset || draggable.offset.click ).top ); return isOverAxis( draggableTop, t, droppable.proportions().height ) && isOverAxis( draggableLeft, l, droppable.proportions().width ); case "touch": return ( ( y1 >= t && y1 <= b ) || // Top edge touching ( y2 >= t && y2 <= b ) || // Bottom edge touching ( y1 < t && y2 > b ) // Surrounded vertically ) && ( ( x1 >= l && x1 <= r ) || // Left edge touching ( x2 >= l && x2 <= r ) || // Right edge touching ( x1 < l && x2 > r ) // Surrounded horizontally ); default: return false; } }; })(); /* This manager tracks offsets of draggables and droppables */ $.ui.ddmanager = { current: null, droppables: { "default": [] }, prepareOffsets: function( t, event ) { var i, j, m = $.ui.ddmanager.droppables[ t.options.scope ] || [], type = event ? event.type : null, // workaround for #2317 list = ( t.currentItem || t.element ).find( ":data(ui-droppable)" ).addBack(); droppablesLoop: for ( i = 0; i < m.length; i++ ) { // No disabled and non-accepted if ( m[ i ].options.disabled || ( t && !m[ i ].accept.call( m[ i ].element[ 0 ], ( t.currentItem || t.element ) ) ) ) { continue; } // Filter out elements in the current dragged item for ( j = 0; j < list.length; j++ ) { if ( list[ j ] === m[ i ].element[ 0 ] ) { m[ i ].proportions().height = 0; continue droppablesLoop; } } m[ i ].visible = m[ i ].element.css( "display" ) !== "none"; if ( !m[ i ].visible ) { continue; } // Activate the droppable if used directly from draggables if ( type === "mousedown" ) { m[ i ]._activate.call( m[ i ], event ); } m[ i ].offset = m[ i ].element.offset(); m[ i ].proportions({ width: m[ i ].element[ 0 ].offsetWidth, height: m[ i ].element[ 0 ].offsetHeight }); } }, drop: function( draggable, event ) { var dropped = false; // Create a copy of the droppables in case the list changes during the drop (#9116) $.each( ( $.ui.ddmanager.droppables[ draggable.options.scope ] || [] ).slice(), function() { if ( !this.options ) { return; } if ( !this.options.disabled && this.visible && $.ui.intersect( draggable, this, this.options.tolerance ) ) { dropped = this._drop.call( this, event ) || dropped; } if ( !this.options.disabled && this.visible && this.accept.call( this.element[ 0 ], ( draggable.currentItem || draggable.element ) ) ) { this.isout = true; this.isover = false; this._deactivate.call( this, event ); } }); return dropped; }, dragStart: function( draggable, event ) { // Listen for scrolling so that if the dragging causes scrolling the position of the droppables can be recalculated (see #5003) draggable.element.parentsUntil( "body" ).bind( "scroll.droppable", function() { if ( !draggable.options.refreshPositions ) { $.ui.ddmanager.prepareOffsets( draggable, event ); } }); }, drag: function( draggable, event ) { // If you have a highly dynamic page, you might try this option. It renders positions every time you move the mouse. if ( draggable.options.refreshPositions ) { $.ui.ddmanager.prepareOffsets( draggable, event ); } // Run through all droppables and check their positions based on specific tolerance options $.each( $.ui.ddmanager.droppables[ draggable.options.scope ] || [], function() { if ( this.options.disabled || this.greedyChild || !this.visible ) { return; } var parentInstance, scope, parent, intersects = $.ui.intersect( draggable, this, this.options.tolerance ), c = !intersects && this.isover ? "isout" : ( intersects && !this.isover ? "isover" : null ); if ( !c ) { return; } if ( this.options.greedy ) { // find droppable parents with same scope scope = this.options.scope; parent = this.element.parents( ":data(ui-droppable)" ).filter(function() { return $( this ).droppable( "instance" ).options.scope === scope; }); if ( parent.length ) { parentInstance = $( parent[ 0 ] ).droppable( "instance" ); parentInstance.greedyChild = ( c === "isover" ); } } // we just moved into a greedy child if ( parentInstance && c === "isover" ) { parentInstance.isover = false; parentInstance.isout = true; parentInstance._out.call( parentInstance, event ); } this[ c ] = true; this[c === "isout" ? "isover" : "isout"] = false; this[c === "isover" ? "_over" : "_out"].call( this, event ); // we just moved out of a greedy child if ( parentInstance && c === "isout" ) { parentInstance.isout = false; parentInstance.isover = true; parentInstance._over.call( parentInstance, event ); } }); }, dragStop: function( draggable, event ) { draggable.element.parentsUntil( "body" ).unbind( "scroll.droppable" ); // Call prepareOffsets one final time since IE does not fire return scroll events when overflow was caused by drag (see #5003) if ( !draggable.options.refreshPositions ) { $.ui.ddmanager.prepareOffsets( draggable, event ); } } }; return $.ui.droppable; })); ;TI"dependency_digest;TI"%1df3eb24e4c2be29a17f9fcbb87991a7;FI"required_paths;T[ I"/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/core.js;FI"|/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/widget.js;FI"{/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/mouse.js;FI"/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/draggable.js;FI"/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/droppable.js;FI"dependency_paths;T[ {I" path;TI"/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/droppable.js;FI" mtime;TI"2014-08-21T17:23:08-04:00;TI" digest;TI"%91c5df5d5000d12d9fa7eb52ffe3f503;F{@!I"/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/core.js;F@#I"2014-08-21T17:23:08-04:00;T@%I"%ad7c7776f3ee907d44f2dc08cbcf5d0b;F{@!I"|/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/widget.js;F@#I"2014-08-21T17:23:08-04:00;T@%I"%d6e208f2fc7c93e326d0ed4ae80449ea;F{@!I"{/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/mouse.js;F@#I"2014-08-21T17:23:08-04:00;T@%I"%afe1e2379a3dc11f53e1857a0c53c3d4;F{@!I"/Users/james/.rbenv/versions/2.1.2/lib/ruby/gems/2.1.0/gems/jquery-ui-rails-5.0.0/app/assets/javascripts/jquery-ui/draggable.js;F@#I"2014-08-21T17:23:08-04:00;T@%I"%6221789fe52ba6d122b29bb36039cfe2;FI" _version;TI"%7ea39fbd96a2fa436855b2c797aedb88;F