Remove the JS part of [31619].

Fixes #6820.

Built from https://develop.svn.wordpress.org/trunk@31960


git-svn-id: http://core.svn.wordpress.org/trunk@31939 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Scott Taylor 2015-04-01 16:34:27 +00:00
parent 62279ae07d
commit 3630732523
6 changed files with 5 additions and 40 deletions

View File

@ -2640,7 +2640,6 @@ Attachment = View.extend({
this.listenTo( this.model, 'change', this.render );
} else {
this.listenTo( this.model, 'change:percent', this.progress );
this.listenTo( this.model, 'change:parent', this.render );
}
this.listenTo( this.model, 'change:title', this._syncTitle );
this.listenTo( this.model, 'change:caption', this._syncCaption );
@ -3180,8 +3179,7 @@ Details = Attachment.extend({
'click .untrash-attachment': 'untrashAttachment',
'click .edit-attachment': 'editAttachment',
'click .refresh-attachment': 'refreshAttachment',
'keydown': 'toggleSelectionHandler',
'click .detach-from-parent': 'detachFromParent'
'keydown': 'toggleSelectionHandler'
},
initialize: function() {
@ -3280,20 +3278,6 @@ Details = Attachment.extend({
this.controller.trigger( 'attachment:keydown:arrow', event );
return;
}
},
/**
* @param {Object} event
*/
detachFromParent: function( event ) {
event.preventDefault();
this.model.save({
'parent' : 0,
'uploadedTo' : 0,
'uploadedToLink' : '',
'uploadedToTitle' : ''
});
}
});

File diff suppressed because one or more lines are too long

View File

@ -52,7 +52,6 @@ Attachment = View.extend({
this.listenTo( this.model, 'change', this.render );
} else {
this.listenTo( this.model, 'change:percent', this.progress );
this.listenTo( this.model, 'change:parent', this.render );
}
this.listenTo( this.model, 'change:title', this._syncTitle );
this.listenTo( this.model, 'change:caption', this._syncCaption );

View File

@ -35,8 +35,7 @@ Details = Attachment.extend({
'click .untrash-attachment': 'untrashAttachment',
'click .edit-attachment': 'editAttachment',
'click .refresh-attachment': 'refreshAttachment',
'keydown': 'toggleSelectionHandler',
'click .detach-from-parent': 'detachFromParent'
'keydown': 'toggleSelectionHandler'
},
initialize: function() {
@ -135,20 +134,6 @@ Details = Attachment.extend({
this.controller.trigger( 'attachment:keydown:arrow', event );
return;
}
},
/**
* @param {Object} event
*/
detachFromParent: function( event ) {
event.preventDefault();
this.model.save({
'parent' : 0,
'uploadedTo' : 0,
'uploadedToLink' : '',
'uploadedToTitle' : ''
});
}
});

View File

@ -418,9 +418,6 @@ function wp_print_media_templates() {
<# } else { #>
<span class="value">{{ data.uploadedToTitle }}</span>
<# } #>
<# if ( data.nonces.edit ) { #>
<a class="detach-from-parent" data-id="{{ data.id }}" href="#">(<?php _e( 'Detach' ); ?>)</a>
<# } #>
</label>
<# } #>
<div class="attachment-compat"></div>

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.2-beta3-31959';
$wp_version = '4.2-beta3-31960';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.