Ticket #13524: 13524.3.patch
| File 13524.3.patch, 1000 bytes (added by , 11 years ago) |
|---|
-
src/wp-admin/js/widgets.js
113 113 } 114 114 }); 115 115 116 var widgetHoverTimeout; 117 116 118 sidebars.sortable({ 117 119 placeholder: 'widget-placeholder', 118 120 items: '> .widget', … … 120 122 cursor: 'move', 121 123 distance: 2, 122 124 containment: 'document', 125 out : function( event, ui ) { 126 clearTimeout( widgetHoverTimeout ); 127 }, 123 128 start: function( event, ui ) { 124 129 var height, $this = $(this), 125 130 $wrap = $this.parent(), … … 135 140 // Prevents jumping when dragging a widget from an open sidebar to a closed sidebar below. 136 141 height = ui.item.hasClass('ui-draggable') ? $this.height() : 1 + $this.height(); 137 142 $this.css( 'min-height', height + 'px' ); 143 } else { 144 widgetHoverTimeout = setTimeout( function() { 145 $wrap.removeClass('closed'); 146 }, 300 ); 138 147 } 139 148 }, 140 149