mirror of
git://develop.git.wordpress.org/
synced 2025-02-28 02:22:25 +01:00
Media: Automatically select uploading attachments in single-select workflows.
The code now automatically selects uploading attachments in all workflows. In a workflow that selects multiple attachments, all attachments added to the upload queue are selected. In a workflow that selects a single attachment (e.g. selecting a featured image), the last attachment added to the upload queue is selected. see #22817. git-svn-id: https://develop.svn.wordpress.org/trunk@23259 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
parent
46e1c12b98
commit
45d01dad51
@ -533,10 +533,12 @@
|
||||
if ( 'upload' === content.mode() )
|
||||
this.frame.content.mode('browse');
|
||||
|
||||
// If we're in a workflow that supports multiple attachments,
|
||||
// automatically select any uploading attachments.
|
||||
if ( this.get('multiple') )
|
||||
this.get('selection').add( attachment );
|
||||
// Automatically select any uploading attachments.
|
||||
//
|
||||
// Selections that don't support multiple attachments automatically
|
||||
// limit themselves to one attachment (in this case, the last
|
||||
// attachment in the upload queue).
|
||||
this.get('selection').add( attachment );
|
||||
},
|
||||
|
||||
saveContentMode: function() {
|
||||
|
Loading…
x
Reference in New Issue
Block a user