diff --git a/wp-includes/js/media-editor.js b/wp-includes/js/media-editor.js index 7078b8cc35..2a3cfd540b 100644 --- a/wp-includes/js/media-editor.js +++ b/wp-includes/js/media-editor.js @@ -304,7 +304,7 @@ editing: true, multiple: true, selection: selection - }); + }).open(); return this.frame; } diff --git a/wp-includes/js/media-views.js b/wp-includes/js/media-views.js index 405d23a620..92d1ba77f2 100644 --- a/wp-includes/js/media-views.js +++ b/wp-includes/js/media-views.js @@ -1141,6 +1141,14 @@ this.on( 'attach', _.bind( this.views.ready, this.views ), this ); }, + render: function() { + // Activate the default state if no active state exists. + if ( ! this.state() && this.options.state ) + this.setState( this.options.state ); + + return media.view.Frame.prototype.render.apply( this, arguments ); + }, + createIframeStates: function( options ) { var settings = media.view.settings, tabs = settings.tabs,