Changeset 28262 for branches/3.9
- Timestamp:
- 05/06/2014 03:27:02 AM (10 years ago)
- Location:
- branches/3.9
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/3.9
-
branches/3.9/src/wp-includes/js/media-views.js
r28229 r28262 3271 3271 overContainer: false, 3272 3272 overDropzone: false, 3273 draggingFile: null, 3273 3274 3274 3275 initialize: function() { … … 3308 3309 supports = supports && !! ( window.File && window.FileList && window.FileReader ); 3309 3310 return supports; 3311 }, 3312 3313 isDraggingFile: function( event ) { 3314 if ( this.draggingFile !== null ) { 3315 return this.draggingFile; 3316 } 3317 3318 if ( _.isUndefined( event.originalEvent ) || _.isUndefined( event.originalEvent.dataTransfer ) ) { 3319 return false; 3320 } 3321 3322 this.draggingFile = _.indexOf( event.originalEvent.dataTransfer.types, 'Files' ) > -1 && 3323 _.indexOf( event.originalEvent.dataTransfer.types, 'text/plain' ) === -1; 3324 3325 return this.draggingFile; 3310 3326 }, 3311 3327 … … 3319 3335 if ( ! _.isUndefined( e ) ) { 3320 3336 $( e.target ).closest( '.uploader-editor' ).toggleClass( 'droppable', this.overDropzone ); 3337 } 3338 3339 if ( ! this.overContainer && ! this.overDropzone ) { 3340 this.draggingFile = null; 3321 3341 } 3322 3342 … … 3384 3404 }, 3385 3405 3386 containerDragover: function( ) {3387 if ( this.localDrag ) {3406 containerDragover: function( event ) { 3407 if ( this.localDrag || ! this.isDraggingFile( event ) ) { 3388 3408 return; 3389 3409 } … … 3400 3420 }, 3401 3421 3402 dropzoneDragover: function( e ) {3403 if ( this.localDrag ) {3422 dropzoneDragover: function( event ) { 3423 if ( this.localDrag || ! this.isDraggingFile( event ) ) { 3404 3424 return; 3405 3425 } 3406 3426 3407 3427 this.overDropzone = true; 3408 this.refresh( e );3428 this.refresh( event ); 3409 3429 return false; 3410 3430 }, -
branches/3.9/src/wp-includes/js/tinymce/plugins/wordpress/plugin.js
r28226 r28262 318 318 if ( typeof window.jQuery !== 'undefined' ) { 319 319 // Trigger the jQuery handlers. 320 window.jQuery( document ).trigger Handler( event.type);320 window.jQuery( document ).trigger( new window.jQuery.Event( event ) ); 321 321 } 322 322 });
Note: See TracChangeset
for help on using the changeset viewer.