<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[27785] trunk/src/wp-includes: There is no more `video-playlist` shortcode.</title>
</head>
<body>

<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt;  }
#msg dl a { font-weight: bold}
#msg dl a:link    { color:#fc3; }
#msg dl a:active  { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff  {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta">
<dt>Revision</dt> <dd><a href="http://core.trac.wordpress.org/changeset/27785">27785</a></dd>
<dt>Author</dt> <dd>wonderboymusic</dd>
<dt>Date</dt> <dd>2014-03-27 17:57:30 +0000 (Thu, 27 Mar 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>There is no more `video-playlist` shortcode. To use video, it is now `[playlist type="video" ....]`. Also deleting core playlist styles. The `style` attribute is still supported, defaulting to `light`. Our core style support was 4-5 CSS rules. 

See <a href="http://core.trac.wordpress.org/ticket/27552">#27552</a>. Leaving open for comments and potential bugs.</pre>

<h3>Modified Paths</h3>
<ul>
<li><a href="#trunksrcwpincludesjsmceviewjs">trunk/src/wp-includes/js/mce-view.js</a></li>
<li><a href="#trunksrcwpincludesjsmediaaudiovideojs">trunk/src/wp-includes/js/media-audiovideo.js</a></li>
<li><a href="#trunksrcwpincludesjsmediaeditorjs">trunk/src/wp-includes/js/media-editor.js</a></li>
<li><a href="#trunksrcwpincludesjsmediaviewsjs">trunk/src/wp-includes/js/media-views.js</a></li>
<li><a href="#trunksrcwpincludesjsmediaelementwpmediaelementjs">trunk/src/wp-includes/js/mediaelement/wp-mediaelement.js</a></li>
<li><a href="#trunksrcwpincludesmediatemplatephp">trunk/src/wp-includes/media-template.php</a></li>
<li><a href="#trunksrcwpincludesmediaphp">trunk/src/wp-includes/media.php</a></li>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunksrcwpincludesjsmceviewjs"></a>
<div class="modfile"><h4>Modified: trunk/src/wp-includes/js/mce-view.js (27784 => 27785)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/src/wp-includes/js/mce-view.js     2014-03-27 17:55:34 UTC (rev 27784)
+++ trunk/src/wp-includes/js/mce-view.js        2014-03-27 17:57:30 UTC (rev 27785)
</span><span class="lines">@@ -364,7 +364,7 @@
</span><span class="cx">          edit: function( node ) {
</span><span class="cx">                  var media = wp.media[ this.shortcode ],
</span><span class="cx">                          self = this,
</span><del>-                               frame, data;
</del><ins>+                                frame, data, callback;
</ins><span class="cx"> 
</span><span class="cx">                  wp.media.mixin.pauseAllPlayers();
</span><span class="cx"> 
</span><span class="lines">@@ -373,12 +373,20 @@
</span><span class="cx">                  frame.on( 'close', function() {
</span><span class="cx">                          frame.detach();
</span><span class="cx">                  } );
</span><del>-                       frame.state( self.state ).on( 'update', function( selection ) {
</del><ins>+
+                       callback = function( selection ) {
</ins><span class="cx">                           var shortcode = wp.media[ self.shortcode ].shortcode( selection ).string();
</span><span class="cx">                          $( node ).attr( 'data-wpview-text', window.encodeURIComponent( shortcode ) );
</span><span class="cx">                          wp.mce.views.refreshView( self, shortcode );
</span><span class="cx">                          frame.detach();
</span><del>-                       } );
</del><ins>+                        };
+                       if ( _.isArray( self.state ) ) {
+                               _.each( self.state, function (state) {
+                                       frame.state( state ).on( 'update', callback );
+                               } );
+                       } else {
+                               frame.state( self.state ).on( 'update', callback );
+                       }
</ins><span class="cx">                   frame.open();
</span><span class="cx">          }
</span><span class="cx">  };
</span><span class="lines">@@ -531,7 +539,7 @@
</span><span class="cx">           * Asynchronously fetch the shortcode's attachments
</span><span class="cx">           */
</span><span class="cx">          fetch: function() {
</span><del>-                       this.attachments = wp.media[ this.shortcode.tag ].attachments( this.shortcode );
</del><ins>+                        this.attachments = wp.media.playlist.attachments( this.shortcode );
</ins><span class="cx">                   this.attachments.more().done( this.setPlayer );
</span><span class="cx">          },
</span><span class="cx"> 
</span><span class="lines">@@ -579,8 +587,7 @@
</span><span class="cx">           */
</span><span class="cx">          getHtml: function() {
</span><span class="cx">                  var data = this.shortcode.attrs.named,
</span><del>-                               model = wp.media[ this.shortcode.tag ],
-                               type = 'playlist' === this.shortcode.tag ? 'audio' : 'video',
</del><ins>+                                model = wp.media.playlist,
</ins><span class="cx">                           options,
</span><span class="cx">                          attachments,
</span><span class="cx">                          tracks = [];
</span><span class="lines">@@ -596,7 +603,7 @@
</span><span class="cx">                  attachments = this.attachments.toJSON();
</span><span class="cx"> 
</span><span class="cx">                  options = {
</span><del>-                               type: type,
</del><ins>+                                type: data.type,
</ins><span class="cx">                           style: data.style,
</span><span class="cx">                          tracklist: data.tracklist,
</span><span class="cx">                          tracknumbers: data.tracknumbers,
</span><span class="lines">@@ -614,7 +621,7 @@
</span><span class="cx">                                  meta : attachment.meta
</span><span class="cx">                          };
</span><span class="cx"> 
</span><del>-                               if ( 'video' === type ) {
</del><ins>+                                if ( 'video' === data.type ) {
</ins><span class="cx">                                   size.width = attachment.width;
</span><span class="cx">                                  size.height = attachment.height;
</span><span class="cx">                                  if ( media.view.settings.contentWidth ) {
</span><span class="lines">@@ -659,20 +666,8 @@
</span><span class="cx">   */
</span><span class="cx">  wp.mce.playlist = _.extend( {}, wp.mce.media, {
</span><span class="cx">          shortcode: 'playlist',
</span><del>-               state: 'playlist-edit',
</del><ins>+                state: ['playlist-edit', 'video-playlist-edit'],
</ins><span class="cx">           View: wp.mce.media.PlaylistView
</span><span class="cx">  } );
</span><span class="cx">  wp.mce.views.register( 'playlist', wp.mce.playlist );
</span><del>-
-       /**
-        * TinyMCE handler for the video-playlist shortcode
-        *
-        * @mixes wp.mce.media
-        */
-       wp.mce['video-playlist'] = _.extend( {}, wp.mce.media, {
-               shortcode: 'video-playlist',
-               state: 'video-playlist-edit',
-               View: wp.mce.media.PlaylistView
-       } );
-       wp.mce.views.register( 'video-playlist', wp.mce['video-playlist'] );
</del><span class="cx"> }(jQuery));
</span></span></pre></div>
<a id="trunksrcwpincludesjsmediaaudiovideojs"></a>
<div class="modfile"><h4>Modified: trunk/src/wp-includes/js/media-audiovideo.js (27784 => 27785)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/src/wp-includes/js/media-audiovideo.js     2014-03-27 17:55:34 UTC (rev 27784)
+++ trunk/src/wp-includes/js/media-audiovideo.js        2014-03-27 17:57:30 UTC (rev 27785)
</span><span class="lines">@@ -176,7 +176,6 @@
</span><span class="cx">   */
</span><span class="cx">  wp.media.playlist = new wp.media.collection({
</span><span class="cx">          tag: 'playlist',
</span><del>-               type : 'audio',
</del><span class="cx">           editTitle : l10n.editPlaylistTitle,
</span><span class="cx">          defaults : {
</span><span class="cx">                  id: wp.media.view.settings.post.id,
</span><span class="lines">@@ -184,23 +183,11 @@
</span><span class="cx">                  tracklist: true,
</span><span class="cx">                  tracknumbers: true,
</span><span class="cx">                  images: true,
</span><del>-                       artists: true
</del><ins>+                        artists: true,
+                       type: 'audio'
</ins><span class="cx">           }
</span><span class="cx">  });
</span><span class="cx"> 
</span><del>-       wp.media['video-playlist'] = new wp.media.collection({
-               tag: 'video-playlist',
-               type : 'video',
-               editTitle : l10n.editVideoPlaylistTitle,
-               defaults : {
-                       id: wp.media.view.settings.post.id,
-                       style: 'light',
-                       tracklist: false,
-                       tracknumbers: false,
-                       images: true
-               }
-       });
-
</del><span class="cx">   /**
</span><span class="cx">   * Shortcode modeling for audio
</span><span class="cx">   *  `edit()` prepares the shortcode for the media modal
</span><span class="lines">@@ -953,96 +940,10 @@
</span><span class="cx"> 
</span><span class="cx">                          counts.audio = a;
</span><span class="cx">                          counts.video = v;
</span><del>-
</del><ins>+                                
</ins><span class="cx">                           return counts;
</span><span class="cx">                  };
</span><del>-               }(media.view.settings)),
-
-               /**
-                * Return the playlist states for MediaFrame.Post
-                *
-                * @param {Object} options
-                * @returns {Array}
-                */
-               states : function(options) {
-                       return [
-                               new media.controller.Library({
-                                       id:         'playlist',
-                                       title:      l10n.createPlaylistTitle,
-                                       priority:   60,
-                                       toolbar:    'main-playlist',
-                                       filterable: 'uploaded',
-                                       multiple:   'add',
-                                       editable:   false,
-
-                                       library:  media.query( _.defaults({
-                                               type: 'audio'
-                                       }, options.library ) )
-                               }),
-
-                               // Playlist states.
-                               new media.controller.CollectionEdit({
-                                       type:           'audio',
-                                       collectionType: 'playlist',
-                                       title:          l10n.editPlaylistTitle,
-                                       SettingsView:   media.view.Settings.Playlist,
-                                       library:        options.selection,
-                                       editing:        options.editing,
-                                       menu:           'playlist',
-                                       dragInfoText:   l10n.playlistDragInfo,
-                                       dragInfo:       false
-                               }),
-
-                               new media.controller.CollectionAdd({
-                                       type: 'audio',
-                                       collectionType: 'playlist',
-                                       title: l10n.addToPlaylistTitle
-                               })
-                       ];
-               },
-
-               /**
-                * Return the video-playlist states for MediaFrame.Post
-                *
-                * @param {Object} options
-                * @returns {Array}
-                */
-               videoStates : function(options) {
-                       return [
-                               new media.controller.Library({
-                                       id:         'video-playlist',
-                                       title:      l10n.createVideoPlaylistTitle,
-                                       priority:   60,
-                                       toolbar:    'main-video-playlist',
-                                       filterable: 'uploaded',
-                                       multiple:   'add',
-                                       editable:   false,
-
-                                       library:  media.query( _.defaults({
-                                               type: 'video'
-                                       }, options.library ) )
-                               }),
-
-                               // Video Playlist states.
-                               new media.controller.CollectionEdit({
-                                       type:           'video',
-                                       collectionType: 'video-playlist',
-                                       title:          l10n.editVideoPlaylistTitle,
-                                       SettingsView:   media.view.Settings.Playlist,
-                                       library:        options.selection,
-                                       editing:        options.editing,
-                                       menu:           'video-playlist',
-                                       dragInfoText:   l10n.videoPlaylistDragInfo,
-                                       dragInfo:       false
-                               }),
-
-                               new media.controller.CollectionAdd({
-                                       type:           'video',
-                                       collectionType: 'video-playlist',
-                                       title:          l10n.addToVideoPlaylistTitle
-                               })
-                       ];
-               }
</del><ins>+                }(media.view.settings))
</ins><span class="cx">   } );
</span><span class="cx"> 
</span><span class="cx">  /**
</span></span></pre></div>
<a id="trunksrcwpincludesjsmediaeditorjs"></a>
<div class="modfile"><h4>Modified: trunk/src/wp-includes/js/media-editor.js (27784 => 27785)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/src/wp-includes/js/media-editor.js 2014-03-27 17:55:34 UTC (rev 27784)
+++ trunk/src/wp-includes/js/media-editor.js    2014-03-27 17:57:30 UTC (rev 27785)
</span><span class="lines">@@ -405,6 +405,11 @@
</span><span class="cx">                                  attrs = _.pick( props, 'orderby', 'order' ),
</span><span class="cx">                                  shortcode, clone, self = this;
</span><span class="cx"> 
</span><ins>+                               if ( attachments.type ) {
+                                       attrs.type = attachments.type;
+                                       delete attachments.type;
+                               }
+
</ins><span class="cx">                           if ( attachments[this.tag] ) {
</span><span class="cx">                                  _.extend( attrs, attachments[this.tag].toJSON() );
</span><span class="cx">                          }
</span><span class="lines">@@ -477,7 +482,7 @@
</span><span class="cx">                  edit: function( content ) {
</span><span class="cx">                          var shortcode = wp.shortcode.next( this.tag, content ),
</span><span class="cx">                                  defaultPostId = this.defaults.id,
</span><del>-                                       attachments, selection;
</del><ins>+                                        attachments, selection, state;
</ins><span class="cx"> 
</span><span class="cx">                          // Bail if we didn't match the shortcode or all of the content.
</span><span class="cx">                          if ( ! shortcode || shortcode.content !== content ) {
</span><span class="lines">@@ -514,10 +519,16 @@
</span><span class="cx">                                  this.frame.dispose();
</span><span class="cx">                          }
</span><span class="cx"> 
</span><del>-                               // Store the current gallery frame.
</del><ins>+                                if ( shortcode.attrs.named.type && 'video' === shortcode.attrs.named.type ) {
+                                       state = 'video-' + this.tag + '-edit';
+                               } else {
+                                       state = this.tag + '-edit';
+                               }
+
+                               // Store the current frame.
</ins><span class="cx">                           this.frame = wp.media({
</span><span class="cx">                                  frame:     'post',
</span><del>-                                       state:     this.tag + '-edit',
</del><ins>+                                        state:     state,
</ins><span class="cx">                                   title:     this.editTitle,
</span><span class="cx">                                  editing:   true,
</span><span class="cx">                                  multiple:  true,
</span><span class="lines">@@ -786,7 +797,7 @@
</span><span class="cx">                          /**
</span><span class="cx">                           * @this wp.media.editor
</span><span class="cx">                           */
</span><del>-                               this.insert( wp.media['video-playlist'].shortcode( selection ).string() );
</del><ins>+                                this.insert( wp.media.playlist.shortcode( selection ).string() );
</ins><span class="cx">                   }, this );
</span><span class="cx"> 
</span><span class="cx">                  workflow.state('embed').on( 'select', function() {
</span></span></pre></div>
<a id="trunksrcwpincludesjsmediaviewsjs"></a>
<div class="modfile"><h4>Modified: trunk/src/wp-includes/js/media-views.js (27784 => 27785)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/src/wp-includes/js/media-views.js  2014-03-27 17:55:34 UTC (rev 27784)
+++ trunk/src/wp-includes/js/media-views.js     2014-03-27 17:57:30 UTC (rev 27785)
</span><span class="lines">@@ -793,6 +793,10 @@
</span><span class="cx">          initialize: function() {
</span><span class="cx">                  var collectionType = this.get('collectionType');
</span><span class="cx"> 
</span><ins>+                       if ( 'video' === this.get( 'type' ) ) {
+                               collectionType = 'video-' + collectionType;
+                       }
+
</ins><span class="cx">                   this.set( 'id', collectionType + '-edit' );
</span><span class="cx">                  this.set( 'toolbar', collectionType + '-edit' );
</span><span class="cx"> 
</span><span class="lines">@@ -1886,7 +1890,7 @@
</span><span class="cx">          },
</span><span class="cx"> 
</span><span class="cx">          createStates: function() {
</span><del>-                       var options = this.options, counts;
</del><ins>+                        var options = this.options;
</ins><span class="cx"> 
</span><span class="cx">                  // Add the default states.
</span><span class="cx">                  this.states.add([
</span><span class="lines">@@ -1946,19 +1950,74 @@
</span><span class="cx">                                  type:           'image',
</span><span class="cx">                                  collectionType: 'gallery',
</span><span class="cx">                                  title:          l10n.addToGalleryTitle
</span><del>-                               })
-                       ]);
</del><ins>+                                }),
</ins><span class="cx"> 
</span><del>-                       counts = media.playlist.counts();
</del><ins>+                                new media.controller.Library({
+                                       id:         'playlist',
+                                       title:      l10n.createPlaylistTitle,
+                                       priority:   60,
+                                       toolbar:    'main-playlist',
+                                       filterable: 'uploaded',
+                                       multiple:   'add',
+                                       editable:   false,
</ins><span class="cx"> 
</span><del>-                       if ( counts.audio ) {
-                               this.states.add( media.playlist.states(options) );
-                       }
</del><ins>+                                        library:  media.query( _.defaults({
+                                               type: 'audio'
+                                       }, options.library ) )
+                               }),
</ins><span class="cx"> 
</span><del>-                       if ( counts.video ) {
-                               this.states.add( media.playlist.videoStates(options) );
-                       }
</del><ins>+                                // Playlist states.
+                               new media.controller.CollectionEdit({
+                                       type: 'audio',
+                                       collectionType: 'playlist',
+                                       title:          l10n.editPlaylistTitle,
+                                       SettingsView:   media.view.Settings.Playlist,
+                                       library:        options.selection,
+                                       editing:        options.editing,
+                                       menu:           'playlist',
+                                       dragInfoText:   l10n.playlistDragInfo,
+                                       dragInfo:       false
+                               }),
</ins><span class="cx"> 
</span><ins>+                               new media.controller.CollectionAdd({
+                                       type: 'audio',
+                                       collectionType: 'playlist',
+                                       title: l10n.addToPlaylistTitle
+                               }),
+
+                               new media.controller.Library({
+                                       id:         'video-playlist',
+                                       title:      l10n.createVideoPlaylistTitle,
+                                       priority:   60,
+                                       toolbar:    'main-video-playlist',
+                                       filterable: 'uploaded',
+                                       multiple:   'add',
+                                       editable:   false,
+
+                                       library:  media.query( _.defaults({
+                                               type: 'video'
+                                       }, options.library ) )
+                               }),
+
+                               new media.controller.CollectionEdit({
+                                       type: 'video',
+                                       collectionType: 'playlist',
+                                       title:          l10n.editVideoPlaylistTitle,
+                                       SettingsView:   media.view.Settings.Playlist,
+                                       library:        options.selection,
+                                       editing:        options.editing,
+                                       menu:           'video-playlist',
+                                       dragInfoText:   l10n.playlistDragInfo,
+                                       dragInfo:       false
+                               }),
+
+                               new media.controller.CollectionAdd({
+                                       type: 'video',
+                                       collectionType: 'playlist',
+                                       title: l10n.addToVideoPlaylistTitle
+                               })
+                       ]);
+
</ins><span class="cx">                   if ( media.view.settings.post.featuredImageId ) {
</span><span class="cx">                          this.states.add( new media.controller.FeaturedImage() );
</span><span class="cx">                  }
</span><span class="lines">@@ -2422,10 +2481,13 @@
</span><span class="cx"> 
</span><span class="cx">                                          click: function() {
</span><span class="cx">                                                  var controller = this.controller,
</span><del>-                                                               state = controller.state();
</del><ins>+                                                                state = controller.state(),
+                                                               library = state.get('library');
</ins><span class="cx"> 
</span><ins>+                                                       library.type = 'video';
+
</ins><span class="cx">                                                   controller.close();
</span><del>-                                                       state.trigger( 'update', state.get('library') );
</del><ins>+                                                        state.trigger( 'update', library );
</ins><span class="cx"> 
</span><span class="cx">                                                  // Restore and reset the default state.
</span><span class="cx">                                                  controller.setState( controller.options.state );
</span></span></pre></div>
<a id="trunksrcwpincludesjsmediaelementwpmediaelementjs"></a>
<div class="modfile"><h4>Modified: trunk/src/wp-includes/js/mediaelement/wp-mediaelement.js (27784 => 27785)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/src/wp-includes/js/mediaelement/wp-mediaelement.js 2014-03-27 17:55:34 UTC (rev 27784)
+++ trunk/src/wp-includes/js/mediaelement/wp-mediaelement.js    2014-03-27 17:57:30 UTC (rev 27785)
</span><span class="lines">@@ -7,6 +7,10 @@
</span><span class="cx">  $(function () {
</span><span class="cx">          var settings = {};
</span><span class="cx"> 
</span><ins>+               if ( $( document.body ).hasClass( 'mce-content-body' ) ) {
+                       return;
+               }
+
</ins><span class="cx">           if ( typeof _wpmejsSettings !== 'undefined' ) {
</span><span class="cx">                  settings.pluginPath = _wpmejsSettings.pluginPath;
</span><span class="cx">          }
</span></span></pre></div>
<a id="trunksrcwpincludesmediatemplatephp"></a>
<div class="modfile"><h4>Modified: trunk/src/wp-includes/media-template.php (27784 => 27785)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/src/wp-includes/media-template.php 2014-03-27 17:55:34 UTC (rev 27784)
+++ trunk/src/wp-includes/media-template.php    2014-03-27 17:57:30 UTC (rev 27785)
</span><span class="lines">@@ -517,53 +517,25 @@
</span><span class="cx">  <script type="text/html" id="tmpl-playlist-settings">
</span><span class="cx">          <h3><?php _e( 'Playlist Settings' ); ?></h3>
</span><span class="cx"> 
</span><del>-               <?php
-               $playlist_styles = array(
-                       'light' => _x( 'Light', 'playlist theme' ),
-                       'dark'  => _x( 'Dark', 'playlist theme' )
-               );
</del><ins>+                <# var emptyModel = _.isEmpty( data.model );  #>
</ins><span class="cx"> 
</span><del>-               /** This filter is documented in wp-includes/media.php */
-               $styles = apply_filters( 'playlist_styles', $playlist_styles );
-
-               if ( ! empty( $styles ) ): ?>
</del><span class="cx">           <label class="setting">
</span><del>-                       <span><?php _e( 'Style' ); ?></span>
-                       <select class="style" data-setting="style">
-                               <?php foreach ( $styles as $slug => $label ): ?>
-                               <option value="<?php echo esc_attr( $slug ) ?>">
-                                       <?php echo $label ?>
-                               </option>
-                               <?php endforeach ?>
-                       </select>
-               </label>
-               <?php endif; ?>
-
-               <#
-                       var playlist = 'playlist-edit' === data.controller.id, emptyModel = _.isEmpty(data.model);
-               #>
-               <label class="setting">
-                       <input type="checkbox" data-setting="_orderbyRandom" />
-                       <span><?php _e( 'Random Order' ); ?></span>
-               </label>
-
-               <label class="setting">
-                       <input type="checkbox" data-setting="tracklist" <# if ( playlist && emptyModel ) { #>
</del><ins>+                        <input type="checkbox" data-setting="tracklist" <# if ( emptyModel ) { #>
</ins><span class="cx">                           checked="checked"
</span><span class="cx">                  <# } #> />
</span><span class="cx">                  <span><?php _e( 'Show Tracklist' ); ?></span>
</span><span class="cx">          </label>
</span><span class="cx"> 
</span><span class="cx">          <label class="setting">
</span><del>-                       <input type="checkbox" data-setting="tracknumbers" <# if ( playlist && emptyModel ) { #>
</del><ins>+                        <input type="checkbox" data-setting="tracknumbers" <# if ( emptyModel ) { #>
</ins><span class="cx">                           checked="checked"
</span><span class="cx">                  <# } #> />
</span><span class="cx">                  <span><?php _e( 'Show Track Numbers' ); ?></span>
</span><span class="cx">          </label>
</span><span class="cx"> 
</span><del>-               <# if ( playlist ) { #>
</del><ins>+                <# if ( 'audio' === data.model.type ) { #>
</ins><span class="cx">           <label class="setting">
</span><del>-                       <input type="checkbox" data-setting="artists" <# if ( playlist && emptyModel ) { #>
</del><ins>+                        <input type="checkbox" data-setting="artists" <# if ( emptyModel ) { #>
</ins><span class="cx">                           checked="checked"
</span><span class="cx">                  <# } #> />
</span><span class="cx">                  <span><?php _e( 'Show Artist Name in Tracklist' ); ?></span>
</span></span></pre></div>
<a id="trunksrcwpincludesmediaphp"></a>
<div class="modfile"><h4>Modified: trunk/src/wp-includes/media.php (27784 => 27785)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/src/wp-includes/media.php  2014-03-27 17:55:34 UTC (rev 27784)
+++ trunk/src/wp-includes/media.php     2014-03-27 17:57:30 UTC (rev 27785)
</span><span class="lines">@@ -1072,17 +1072,12 @@
</span><span class="cx">  * @since 3.9.0
</span><span class="cx">  *
</span><span class="cx">  * @param array  $attr Attributes of the shortcode.
</span><del>- * @param string $type Type of playlist. Accepts 'audio' and 'video'.
</del><span class="cx">  * @return string Playlist output. Empty string if the passed type is unsupported.
</span><span class="cx">  */
</span><del>-function wp_get_playlist( $attr, $type ) {
</del><ins>+function wp_playlist_shortcode( $attr ) {
</ins><span class="cx">   global $content_width;
</span><span class="cx">  $post = get_post();
</span><span class="cx"> 
</span><del>-       if ( ! in_array( $type, array( 'audio', 'video' ) ) ) {
-               return '';
-       }
-
</del><span class="cx">   static $instance = 0;
</span><span class="cx">  $instance++;
</span><span class="cx"> 
</span><span class="lines">@@ -1106,7 +1101,7 @@
</span><span class="cx">   * @param array  $attr   Array of shortcode attributes.
</span><span class="cx">   * @param string $type   Type of playlist to generate output for.
</span><span class="cx">   */
</span><del>-       $output = apply_filters( 'post_playlist', '', $attr, $type );
</del><ins>+        $output = apply_filters( 'post_playlist', '', $attr );
</ins><span class="cx">   if ( $output != '' ) {
</span><span class="cx">          return $output;
</span><span class="cx">  }
</span><span class="lines">@@ -1122,14 +1117,15 @@
</span><span class="cx">  }
</span><span class="cx"> 
</span><span class="cx">  extract( shortcode_atts( array(
</span><ins>+               'type'          => 'audio',
</ins><span class="cx">           'order'         => 'ASC',
</span><span class="cx">          'orderby'       => 'menu_order ID',
</span><span class="cx">          'id'            => $post ? $post->ID : 0,
</span><span class="cx">          'include'       => '',
</span><span class="cx">          'exclude'   => '',
</span><span class="cx">          'style'         => 'light',
</span><del>-               'tracklist' => 'audio' === $type,
-               'tracknumbers' => 'audio' === $type,
</del><ins>+                'tracklist' => true,
+               'tracknumbers' => true,
</ins><span class="cx">           'images'        => true,
</span><span class="cx">          'artists'       => true
</span><span class="cx">  ), $attr, 'playlist' ) );
</span><span class="lines">@@ -1139,24 +1135,6 @@
</span><span class="cx">          $orderby = 'none';
</span><span class="cx">  }
</span><span class="cx"> 
</span><del>-       $playlist_styles = array(
-               'light' => _x( 'Light', 'playlist theme' ),
-               'dark'  => _x( 'Dark', 'playlist theme' )
-       );
-
-       /**
-        * Filter the available playlist styles.
-        *
-        * @since 3.9.0
-        *
-        * @param array $playlist_styles Array of playlist styles. Defaults are 'light' and 'dark'.
-        */
-       $styles = apply_filters( 'playlist_styles', $playlist_styles );
-
-       if ( ! in_array( $style, array_keys( $styles ), true ) ) {
-               $style = 'light';
-       }
-
</del><span class="cx">   $args = array(
</span><span class="cx">          'post_status' => 'inherit',
</span><span class="cx">          'post_type' => 'attachment',
</span><span class="lines">@@ -1202,7 +1180,7 @@
</span><span class="cx">  $theme_width = empty( $content_width ) ? $default_width : ( $content_width - $outer );
</span><span class="cx">  $theme_height = empty( $content_width ) ? $default_height : round( ( $default_height * $theme_width ) / $default_width );
</span><span class="cx"> 
</span><del>-       $data = compact( 'type', 'style' );
</del><ins>+        $data = compact( 'type' );
</ins><span class="cx"> 
</span><span class="cx">  // don't pass strings to JSON, will be truthy in JS
</span><span class="cx">  foreach ( array( 'tracklist', 'tracknumbers', 'images', 'artists' ) as $key ) {
</span><span class="lines">@@ -1311,34 +1289,9 @@
</span><span class="cx">  <?php
</span><span class="cx">  return ob_get_clean();
</span><span class="cx"> }
</span><del>-
-/**
- * Playlist shortcode handler
- *
- * @since 3.9.0
- *
- * @param array $attr Parsed shortcode attributes.
- * @return string The resolved playlist shortcode markup.
- */
-function wp_playlist_shortcode( $attr ) {
-       return wp_get_playlist( $attr, 'audio' );
-}
</del><span class="cx"> add_shortcode( 'playlist', 'wp_playlist_shortcode' );
</span><span class="cx"> 
</span><span class="cx"> /**
</span><del>- * Video playlist shortcode handler
- *
- * @since 3.9.0
- *
- * @param array $attr Parsed shortcode attributes.
- * @return string The resolved video playlist shortcode markup.
- */
-function wp_video_playlist_shortcode( $attr ) {
-       return wp_get_playlist( $attr, 'video' );
-}
-add_shortcode( 'video-playlist', 'wp_video_playlist_shortcode' );
-
-/**
</del><span class="cx">  * Provide a No-JS Flash fallback as a last resort for audio / video
</span><span class="cx">  *
</span><span class="cx">  * @since 3.6.0
</span></span></pre>
</div>
</div>

</body>
</html>