<!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>[27266] trunk/src/wp-includes/js: Fixed mixed spaces and tabs.</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/27266">27266</a></dd>
<dt>Author</dt> <dd>nacin</dd>
<dt>Date</dt> <dd>2014-02-25 17:31:19 +0000 (Tue, 25 Feb 2014)</dd>
</dl>

<h3>Log Message</h3>
<pre>Fixed mixed spaces and tabs. Also remove trailing comma. see <a href="http://core.trac.wordpress.org/ticket/26631">#26631</a>.</pre>

<h3>Modified Paths</h3>
<ul>
<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>
</ul>

</div>
<div id="patch">
<h3>Diff</h3>
<a id="trunksrcwpincludesjsmediaeditorjs"></a>
<div class="modfile"><h4>Modified: trunk/src/wp-includes/js/media-editor.js (27265 => 27266)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/src/wp-includes/js/media-editor.js 2014-02-25 17:28:54 UTC (rev 27265)
+++ trunk/src/wp-includes/js/media-editor.js    2014-02-25 17:31:19 UTC (rev 27266)
</span><span class="lines">@@ -292,26 +292,26 @@
</span><span class="cx">                   *                      containing the 'props' for the gallery.
</span><span class="cx">                   */
</span><span class="cx">                  return function( shortcode ) {
</span><del>-                               var shortcodeString = shortcode.string(),
-                                       result = cache[ shortcodeString ],
-                                       attrs, args, query, others;
</del><ins>+                                var shortcodeString = shortcode.string(),
+                                       result = cache[ shortcodeString ],
+                                       attrs, args, query, others;
</ins><span class="cx"> 
</span><del>-                               delete cache[ shortcodeString ];
</del><ins>+                                delete cache[ shortcodeString ];
</ins><span class="cx"> 
</span><del>-                               if ( result ) {
-                                       return result;
</del><ins>+                                if ( result ) {
+                                       return result;
</ins><span class="cx">                           }
</span><span class="cx"> 
</span><del>-                               // Fill the default shortcode attributes.
-                               attrs = _.defaults( shortcode.attrs.named, this.defaults );
-                               args  = _.pick( attrs, 'orderby', 'order' );
</del><ins>+                                // Fill the default shortcode attributes.
+                               attrs = _.defaults( shortcode.attrs.named, this.defaults );
+                               args  = _.pick( attrs, 'orderby', 'order' );
</ins><span class="cx"> 
</span><del>-                               args.type = type;
-                               args.perPage = -1;
</del><ins>+                                args.type = type;
+                               args.perPage = -1;
</ins><span class="cx"> 
</span><del>-                               // Mark the `orderby` override attribute.
-                               if ( undefined !== attrs.orderby ) {
-                                       attrs._orderByField = attrs.orderby;
</del><ins>+                                // Mark the `orderby` override attribute.
+                               if ( undefined !== attrs.orderby ) {
+                                       attrs._orderByField = attrs.orderby;
</ins><span class="cx">                           }
</span><span class="cx"> 
</span><span class="cx">                          if ( 'rand' === attrs.orderby ) {
</span><span class="lines">@@ -358,40 +358,40 @@
</span><span class="cx">                  };
</span><span class="cx">          },
</span><span class="cx"> 
</span><del>-               shortcodeAttrs : function ( prop, attachments ) {
-                       var props = attachments.props.toJSON(),
-                               attrs = _.pick( props, 'orderby', 'order', 'style' );
</del><ins>+                shortcodeAttrs : function ( prop, attachments ) {
+                       var props = attachments.props.toJSON(),
+                               attrs = _.pick( props, 'orderby', 'order', 'style' );
</ins><span class="cx"> 
</span><del>-                       if ( attachments[ prop ] ) {
-                               _.extend( attrs, attachments[ prop ].toJSON() );
</del><ins>+                        if ( attachments[ prop ] ) {
+                               _.extend( attrs, attachments[ prop ].toJSON() );
</ins><span class="cx">                   }
</span><span class="cx"> 
</span><del>-                       // Convert all collection shortcodes to use the `ids` property.
-                       // Ignore `post__in` and `post__not_in`; the attachments in
-                       // the collection will already reflect those properties.
-                       attrs.ids = attachments.pluck('id');
</del><ins>+                        // Convert all collection shortcodes to use the `ids` property.
+                       // Ignore `post__in` and `post__not_in`; the attachments in
+                       // the collection will already reflect those properties.
+                       attrs.ids = attachments.pluck('id');
</ins><span class="cx"> 
</span><del>-                       // Copy the `uploadedTo` post ID.
-                       if ( props.uploadedTo ) {
-                               attrs.id = props.uploadedTo;
</del><ins>+                        // Copy the `uploadedTo` post ID.
+                       if ( props.uploadedTo ) {
+                               attrs.id = props.uploadedTo;
</ins><span class="cx">                   }
</span><span class="cx"> 
</span><del>-                       // Check if the collection is randomly ordered.
-                       delete attrs.orderby;
</del><ins>+                        // Check if the collection is randomly ordered.
+                       delete attrs.orderby;
</ins><span class="cx"> 
</span><del>-                       if ( attrs._orderbyRandom ) {
-                               attrs.orderby = 'rand';
</del><ins>+                        if ( attrs._orderbyRandom ) {
+                               attrs.orderby = 'rand';
</ins><span class="cx">                   } else if ( attrs._orderByField && attrs._orderByField != 'rand' ) {
</span><del>-                               attrs.orderby = attrs._orderByField;
</del><ins>+                                attrs.orderby = attrs._orderByField;
</ins><span class="cx">                   }
</span><span class="cx"> 
</span><del>-                       delete attrs._orderbyRandom;
</del><ins>+                        delete attrs._orderbyRandom;
</ins><span class="cx">                   delete attrs._orderByField;
</span><span class="cx"> 
</span><del>-                       // If the `ids` attribute is set and `orderby` attribute
-                       // is the default value, clear it for cleaner output.
-                       if ( attrs.ids && 'post__in' === attrs.orderby ) {
-                               delete attrs.orderby;
</del><ins>+                        // If the `ids` attribute is set and `orderby` attribute
+                       // is the default value, clear it for cleaner output.
+                       if ( attrs.ids && 'post__in' === attrs.orderby ) {
+                               delete attrs.orderby;
</ins><span class="cx">                   }
</span><span class="cx"> 
</span><span class="cx">                  if ( -1 !== jQuery.inArray( prop, ['playlist', 'video-playlist'] ) ) {
</span><span class="lines">@@ -405,46 +405,46 @@
</span><span class="cx">                          });
</span><span class="cx">                  }
</span><span class="cx"> 
</span><del>-                       // Remove default attributes from the shortcode.
-                       _.each( wp.media[prop].defaults, function( value, key ) {
-                               if ( value === attrs[ key ] ) {
-                                       delete attrs[ key ];
</del><ins>+                        // Remove default attributes from the shortcode.
+                       _.each( wp.media[prop].defaults, function( value, key ) {
+                               if ( value === attrs[ key ] ) {
+                                       delete attrs[ key ];
</ins><span class="cx">                           }
</span><del>-                       });
-                       return attrs;
-               },
</del><ins>+                        });
+                       return attrs;
+               },
</ins><span class="cx"> 
</span><del>-               editSelection : function ( prop, shortcode ) {
-                       var defaultPostId = wp.media[ prop ].defaults.id,
</del><ins>+                editSelection : function ( prop, shortcode ) {
+                       var defaultPostId = wp.media[ prop ].defaults.id,
</ins><span class="cx">                           attachments, selection;
</span><span class="cx"> 
</span><del>-                       // Ignore the rest of the match object.
-                       shortcode = shortcode.shortcode;
</del><ins>+                        // Ignore the rest of the match object.
+                       shortcode = shortcode.shortcode;
</ins><span class="cx"> 
</span><del>-                       if ( _.isUndefined( shortcode.get('id') ) && ! _.isUndefined( defaultPostId ) ) {
-                               shortcode.set( 'id', defaultPostId );
</del><ins>+                        if ( _.isUndefined( shortcode.get('id') ) && ! _.isUndefined( defaultPostId ) ) {
+                               shortcode.set( 'id', defaultPostId );
</ins><span class="cx">                   }
</span><span class="cx"> 
</span><del>-                       attachments = wp.media[ prop ].attachments( shortcode );
</del><ins>+                        attachments = wp.media[ prop ].attachments( shortcode );
</ins><span class="cx"> 
</span><del>-                       selection = new wp.media.model.Selection( attachments.models, {
-                               props:    attachments.props.toJSON(),
-                               multiple: true
-                       });
</del><ins>+                        selection = new wp.media.model.Selection( attachments.models, {
+                               props:    attachments.props.toJSON(),
+                               multiple: true
+                       });
</ins><span class="cx"> 
</span><del>-                       selection[ prop ] = attachments[ prop ];
</del><ins>+                        selection[ prop ] = attachments[ prop ];
</ins><span class="cx"> 
</span><del>-                       // Fetch the query's attachments, and then break ties from the
</del><ins>+                        // Fetch the query's attachments, and then break ties from the
</ins><span class="cx">                   // query to allow for sorting.
</span><del>-                       selection.more().done( function() {
-                               // Break ties with the query.
-                               selection.props.set({ query: false });
-                               selection.unmirror();
-                               selection.props.unset('orderby');
-                       });
</del><ins>+                        selection.more().done( function() {
+                               // Break ties with the query.
+                               selection.props.set({ query: false });
+                               selection.unmirror();
+                               selection.props.unset('orderby');
+                       });
</ins><span class="cx"> 
</span><del>-                       return selection;
-               },
</del><ins>+                        return selection;
+               },
</ins><span class="cx"> 
</span><span class="cx">          /**
</span><span class="cx">           *
</span><span class="lines">@@ -453,36 +453,36 @@
</span><span class="cx">           * @param {wp.shortcode} shortcode
</span><span class="cx">           * @returns {wp.shortcode}
</span><span class="cx">           */
</span><del>-               cacheShortcode : function ( prop, attachments, shortcode ) {
-                       // Use a cloned version of the playlist.
-                       var clone = new wp.media.model.Attachments( attachments.models, {
-                               props: attachments.props.toJSON()
-                       });
-                       clone[ prop ] = attachments[ prop ];
-                       cache[ shortcode.string() ] = clone;
</del><ins>+                cacheShortcode : function ( prop, attachments, shortcode ) {
+                       // Use a cloned version of the playlist.
+                       var clone = new wp.media.model.Attachments( attachments.models, {
+                               props: attachments.props.toJSON()
+                       });
+                       clone[ prop ] = attachments[ prop ];
+                       cache[ shortcode.string() ] = clone;
</ins><span class="cx"> 
</span><del>-                       return shortcode;
-               },
</del><ins>+                        return shortcode;
+               },
</ins><span class="cx"> 
</span><del>-               getEditFrame : function ( args ) {
-                       // Destroy the previous gallery frame.
-                       if ( this.frame ) {
-                               this.frame.dispose();
</del><ins>+                getEditFrame : function ( args ) {
+                       // Destroy the previous gallery frame.
+                       if ( this.frame ) {
+                               this.frame.dispose();
</ins><span class="cx">                   }
</span><span class="cx"> 
</span><del>-                       // Store the current gallery frame.
-                       this.frame = wp.media( _.extend( {
-                               frame:     'post',
-                               editing:   true,
-                               multiple:  true,
-                       }, args ) ).open();
</del><ins>+                        // Store the current gallery frame.
+                       this.frame = wp.media( _.extend( {
+                               frame:     'post',
+                               editing:   true,
+                               multiple:  true
+                       }, args ) ).open();
</ins><span class="cx"> 
</span><del>-                       return this.frame;
-               },
</del><ins>+                        return this.frame;
+               },
</ins><span class="cx"> 
</span><del>-               instance : function ( prop, args ) {
-                       return {
-                               attachments: this.attachments( prop, args.type ),
</del><ins>+                instance : function ( prop, args ) {
+                       return {
+                               attachments: this.attachments( prop, args.type ),
</ins><span class="cx">                           /**
</span><span class="cx">                           * Triggered when clicking 'Insert {label}' or 'Update {label}'
</span><span class="cx">                           *
</span><span class="lines">@@ -495,14 +495,14 @@
</span><span class="cx">                           *                      containing the 'props' for the gallery.
</span><span class="cx">                           * @returns {wp.shortcode}
</span><span class="cx">                           */
</span><del>-                               shortcode: function( attachments ) {
-                                       var shortcode = new wp.shortcode({
-                                               tag: prop,
-                                               attrs: wp.media.collection.shortcodeAttrs( prop, attachments ),
-                                               type: 'single'
-                                       });
</del><ins>+                                shortcode: function( attachments ) {
+                                       var shortcode = new wp.shortcode({
+                                               tag: prop,
+                                               attrs: wp.media.collection.shortcodeAttrs( prop, attachments ),
+                                               type: 'single'
+                                       });
</ins><span class="cx"> 
</span><del>-                                       return wp.media.collection.cacheShortcode( prop, attachments, shortcode );
</del><ins>+                                        return wp.media.collection.cacheShortcode( prop, attachments, shortcode );
</ins><span class="cx">                           },
</span><span class="cx">                          /**
</span><span class="cx">                           * Triggered when double-clicking a collection shortcode placeholder
</span><span class="lines">@@ -519,44 +519,44 @@
</span><span class="cx">                           *
</span><span class="cx">                           * @returns {wp.media.view.MediaFrame.Select} A media workflow.
</span><span class="cx">                           */
</span><del>-                               edit: function( content ) {
-                                       var shortcode = wp.shortcode.next( prop, content );
</del><ins>+                                edit: function( content ) {
+                                       var shortcode = wp.shortcode.next( prop, content );
</ins><span class="cx"> 
</span><del>-                                       // Bail if we didn't match the shortcode or all of the content.
-                                       if ( ! shortcode || shortcode.content !== content ) {
-                                               return;
</del><ins>+                                        // Bail if we didn't match the shortcode or all of the content.
+                                       if ( ! shortcode || shortcode.content !== content ) {
+                                               return;
</ins><span class="cx">                                   }
</span><span class="cx"> 
</span><del>-                                       return wp.media.collection.getEditFrame( {
-                                               title: args.title,
-                                               state: prop + '-edit',
-                                               selection:      wp.media.collection.editSelection( prop, shortcode )
-                                       } );
-                               }
-                       };
-               }
</del><ins>+                                        return wp.media.collection.getEditFrame( {
+                                               title: args.title,
+                                               state: prop + '-edit',
+                                               selection:      wp.media.collection.editSelection( prop, shortcode )
+                                       } );
+                               }
+                       };
+               }
</ins><span class="cx">   };
</span><span class="cx"> 
</span><del>-       wp.media.gallery = (function() {
-               var gallery = {
-                       defaults : {
</del><ins>+        wp.media.gallery = (function() {
+               var gallery = {
+                       defaults : {
</ins><span class="cx">                           itemtag: 'dl',
</span><span class="cx">                          icontag: 'dt',
</span><span class="cx">                          captiontag: 'dd',
</span><del>-                               columns: '3',
</del><ins>+                                columns: '3',
</ins><span class="cx">                           link: 'post',
</span><span class="cx">                          size: 'thumbnail',
</span><del>-                               order: 'ASC',
-                               id: wp.media.view.settings.post.id,
-                               orderby : 'menu_order ID'
-                       }
-               };
</del><ins>+                                order: 'ASC',
+                               id: wp.media.view.settings.post.id,
+                               orderby : 'menu_order ID'
+                       }
+               };
</ins><span class="cx"> 
</span><del>-               return _.extend(gallery, wp.media.collection.instance( 'gallery', {
-                       type : 'image',
-                       title : wp.media.view.l10n.editGalleryTitle
-               }));
-       }());
</del><ins>+                return _.extend(gallery, wp.media.collection.instance( 'gallery', {
+                       type : 'image',
+                       title : wp.media.view.l10n.editGalleryTitle
+               }));
+       }());
</ins><span class="cx"> 
</span><span class="cx">  wp.media.playlist = (function() {
</span><span class="cx">          var playlist = {
</span></span></pre></div>
<a id="trunksrcwpincludesjsmediaviewsjs"></a>
<div class="modfile"><h4>Modified: trunk/src/wp-includes/js/media-views.js (27265 => 27266)</h4>
<pre class="diff"><span>
<span class="info">--- trunk/src/wp-includes/js/media-views.js  2014-02-25 17:28:54 UTC (rev 27265)
+++ trunk/src/wp-includes/js/media-views.js     2014-02-25 17:31:19 UTC (rev 27266)
</span><span class="lines">@@ -767,102 +767,102 @@
</span><span class="cx">   * @param {object} args
</span><span class="cx">   * @returns {wp.media.controller.Library}
</span><span class="cx">   */
</span><del>-       media.controller.CollectionEdit = function ( prop, args ) {
</del><ins>+        media.controller.CollectionEdit = function ( prop, args ) {
</ins><span class="cx">           /**
</span><span class="cx">           * @constructor
</span><span class="cx">           * @augments wp.media.controller.Library
</span><span class="cx">           * @augments wp.media.controller.State
</span><span class="cx">           * @augments Backbone.Model
</span><span class="cx">           */
</span><del>-               return media.controller.Library.extend({
-                       defaults : _.defaults(args.defaults || {}, {
-                               id:         prop + '-edit',
-                               toolbar:    prop + '-edit',
-                               multiple:   false,
-                               describe:   true,
-                               edge:       199,
-                               editing:    false,
-                               sortable:   true,
-                               searchable: false,
-                               content:    'browse',
-                               priority:   60,
-                               dragInfo:   true,
</del><ins>+                return media.controller.Library.extend({
+                       defaults : _.defaults(args.defaults || {}, {
+                               id:         prop + '-edit',
+                               toolbar:    prop + '-edit',
+                               multiple:   false,
+                               describe:   true,
+                               edge:       199,
+                               editing:    false,
+                               sortable:   true,
+                               searchable: false,
+                               content:    'browse',
+                               priority:   60,
+                               dragInfo:   true,
</ins><span class="cx"> 
</span><del>-                               // Don't sync the selection, as the Edit {Collection} library
-                               // *is* the selection.
-                               syncSelection: false
-                       }),
</del><ins>+                                // Don't sync the selection, as the Edit {Collection} library
+                               // *is* the selection.
+                               syncSelection: false
+                       }),
</ins><span class="cx"> 
</span><del>-                       initialize: function() {
-                               // If we haven't been provided a `library`, create a `Selection`.
-                               if ( ! this.get('library') ) {
-                                       this.set( 'library', new media.model.Selection() );
</del><ins>+                        initialize: function() {
+                               // If we haven't been provided a `library`, create a `Selection`.
+                               if ( ! this.get('library') ) {
+                                       this.set( 'library', new media.model.Selection() );
</ins><span class="cx">                           }
</span><del>-                               // The single `Attachment` view to be used in the `Attachments` view.
-                               if ( ! this.get('AttachmentView') ) {
-                                       this.set( 'AttachmentView', media.view.Attachment.EditLibrary );
</del><ins>+                                // The single `Attachment` view to be used in the `Attachments` view.
+                               if ( ! this.get('AttachmentView') ) {
+                                       this.set( 'AttachmentView', media.view.Attachment.EditLibrary );
</ins><span class="cx">                           }
</span><del>-                               media.controller.Library.prototype.initialize.apply( this, arguments );
-                       },
</del><ins>+                                media.controller.Library.prototype.initialize.apply( this, arguments );
+                       },
</ins><span class="cx"> 
</span><del>-                       activate: function() {
-                               var library = this.get('library');
</del><ins>+                        activate: function() {
+                               var library = this.get('library');
</ins><span class="cx"> 
</span><del>-                               // Limit the library to images only.
-                               library.props.set( 'type', args.type );
</del><ins>+                                // Limit the library to images only.
+                               library.props.set( 'type', args.type );
</ins><span class="cx"> 
</span><del>-                               // Watch for uploaded attachments.
-                               this.get('library').observe( wp.Uploader.queue );
</del><ins>+                                // Watch for uploaded attachments.
+                               this.get('library').observe( wp.Uploader.queue );
</ins><span class="cx"> 
</span><del>-                               this.frame.on( 'content:render:browse', this.settings, this );
</del><ins>+                                this.frame.on( 'content:render:browse', this.settings, this );
</ins><span class="cx"> 
</span><del>-                               media.controller.Library.prototype.activate.apply( this, arguments );
-                       },
</del><ins>+                                media.controller.Library.prototype.activate.apply( this, arguments );
+                       },
</ins><span class="cx"> 
</span><del>-                       deactivate: function() {
-                               // Stop watching for uploaded attachments.
-                               this.get('library').unobserve( wp.Uploader.queue );
</del><ins>+                        deactivate: function() {
+                               // Stop watching for uploaded attachments.
+                               this.get('library').unobserve( wp.Uploader.queue );
</ins><span class="cx"> 
</span><del>-                               this.frame.off( 'content:render:browse', this.settings, this );
</del><ins>+                                this.frame.off( 'content:render:browse', this.settings, this );
</ins><span class="cx"> 
</span><del>-                               media.controller.Library.prototype.deactivate.apply( this, arguments );
-                       },
</del><ins>+                                media.controller.Library.prototype.deactivate.apply( this, arguments );
+                       },
</ins><span class="cx"> 
</span><del>-                       settings: function( browser ) {
-                               var library = this.get('library'), obj = {};
</del><ins>+                        settings: function( browser ) {
+                               var library = this.get('library'), obj = {};
</ins><span class="cx"> 
</span><del>-                               if ( ! library || ! browser ) {
-                                       return;
</del><ins>+                                if ( ! library || ! browser ) {
+                                       return;
</ins><span class="cx">                           }
</span><span class="cx"> 
</span><del>-                               library[ prop ] = library[ prop ] || new Backbone.Model();
</del><ins>+                                library[ prop ] = library[ prop ] || new Backbone.Model();
</ins><span class="cx"> 
</span><del>-                               obj[ prop ] = new media.view.Settings[ args.settings ]({
-                                       controller: this,
-                                       model:      library[ prop ],
-                                       priority:   40
-                               });
</del><ins>+                                obj[ prop ] = new media.view.Settings[ args.settings ]({
+                                       controller: this,
+                                       model:      library[ prop ],
+                                       priority:   40
+                               });
</ins><span class="cx"> 
</span><del>-                               browser.sidebar.set( obj );
</del><ins>+                                browser.sidebar.set( obj );
</ins><span class="cx"> 
</span><del>-                               if ( args.dragInfoText ) {
-                                       browser.toolbar.set( 'dragInfo', new media.View({
-                                               el: $( '<div class="instructions">' + args.dragInfoText + '</div>' )[0],
-                                               priority: -40
-                                       }) );
-                               }
</del><ins>+                                if ( args.dragInfoText ) {
+                                       browser.toolbar.set( 'dragInfo', new media.View({
+                                               el: $( '<div class="instructions">' + args.dragInfoText + '</div>' )[0],
+                                               priority: -40
+                                       }) );
+                               }
</ins><span class="cx"> 
</span><del>-                               browser.toolbar.set( 'reverse', {
-                                       text:     l10n.reverseOrder,
-                                       priority: 80,
</del><ins>+                                browser.toolbar.set( 'reverse', {
+                                       text:     l10n.reverseOrder,
+                                       priority: 80,
</ins><span class="cx"> 
</span><del>-                                       click: function() {
-                                               library.reset( library.toArray().reverse() );
-                                       }
-                               });
-                       }
-               });
-       };
</del><ins>+                                        click: function() {
+                                               library.reset( library.toArray().reverse() );
+                                       }
+                               });
+                       }
+               });
+       };
</ins><span class="cx"> 
</span><span class="cx">  /**
</span><span class="cx">   * wp.media.controller.CollectionAdd
</span><span class="lines">@@ -872,56 +872,56 @@
</span><span class="cx">   * @param {object} args
</span><span class="cx">   * @returns {wp.media.controller.Library}
</span><span class="cx">   */
</span><del>-       media.controller.CollectionAdd = function ( prop, args ) {
</del><ins>+        media.controller.CollectionAdd = function ( prop, args ) {
</ins><span class="cx">           /**
</span><span class="cx">           * @constructor
</span><span class="cx">           * @augments wp.media.controller.Library
</span><span class="cx">           * @augments wp.media.controller.State
</span><span class="cx">           * @augments Backbone.Model
</span><span class="cx">           */
</span><del>-               return media.controller.Library.extend({
-                       defaults: _.defaults({
-                               id:           prop + '-library',
-                               filterable:   'uploaded',
-                               multiple:     'add',
-                               menu:         prop,
-                               toolbar:      prop + '-add',
-                               priority:     100,
-                               syncSelection: false
-                       }, args.defaults || {}, media.controller.Library.prototype.defaults ),
-                       initialize: function() {
-                               // If we haven't been provided a `library`, create a `Selection`.
-                               if ( ! this.get('library') ) {
-                                       this.set( 'library', media.query({ type: args.type }) );
</del><ins>+                return media.controller.Library.extend({
+                       defaults: _.defaults({
+                               id:           prop + '-library',
+                               filterable:   'uploaded',
+                               multiple:     'add',
+                               menu:         prop,
+                               toolbar:      prop + '-add',
+                               priority:     100,
+                               syncSelection: false
+                       }, args.defaults || {}, media.controller.Library.prototype.defaults ),
+                       initialize: function() {
+                               // If we haven't been provided a `library`, create a `Selection`.
+                               if ( ! this.get('library') ) {
+                                       this.set( 'library', media.query({ type: args.type }) );
</ins><span class="cx">                           }
</span><del>-                               media.controller.Library.prototype.initialize.apply( this, arguments );
-                       },
</del><ins>+                                media.controller.Library.prototype.initialize.apply( this, arguments );
+                       },
</ins><span class="cx"> 
</span><span class="cx">                  activate: function() {
</span><del>-                               var library = this.get('library'),
-                                       edit    = this.frame.state(prop + '-edit').get('library');
</del><ins>+                                var library = this.get('library'),
+                                       edit    = this.frame.state(prop + '-edit').get('library');
</ins><span class="cx"> 
</span><del>-                               if ( this.editLibrary && this.editLibrary !== edit ) {
-                                       library.unobserve( this.editLibrary );
</del><ins>+                                if ( this.editLibrary && this.editLibrary !== edit ) {
+                                       library.unobserve( this.editLibrary );
</ins><span class="cx">                           }
</span><span class="cx"> 
</span><del>-                               // Accepts attachments that exist in the original library and
-                               // that do not exist in gallery's library.
-                               library.validator = function( attachment ) {
-                                       return !! this.mirroring.get( attachment.cid ) && ! edit.get( attachment.cid ) && media.model.Selection.prototype.validator.apply( this, arguments );
-                               };
</del><ins>+                                // Accepts attachments that exist in the original library and
+                               // that do not exist in gallery's library.
+                               library.validator = function( attachment ) {
+                                       return !! this.mirroring.get( attachment.cid ) && ! edit.get( attachment.cid ) && media.model.Selection.prototype.validator.apply( this, arguments );
+                               };
</ins><span class="cx"> 
</span><del>-                               // Reset the library to ensure that all attachments are re-added
-                               // to the collection. Do so silently, as calling `observe` will
-                               // trigger the `reset` event.
-                               library.reset( library.mirroring.models, { silent: true });
-                               library.observe( edit );
-                               this.editLibrary = edit;
</del><ins>+                                // Reset the library to ensure that all attachments are re-added
+                               // to the collection. Do so silently, as calling `observe` will
+                               // trigger the `reset` event.
+                               library.reset( library.mirroring.models, { silent: true });
+                               library.observe( edit );
+                               this.editLibrary = edit;
</ins><span class="cx"> 
</span><del>-                               media.controller.Library.prototype.activate.apply( this, arguments );
-                       }
-               });
-       };
</del><ins>+                                media.controller.Library.prototype.activate.apply( this, arguments );
+                       }
+               });
+       };
</ins><span class="cx"> 
</span><span class="cx">  // wp.media.controller.GalleryEdit
</span><span class="cx">  // -------------------------------
</span><span class="lines">@@ -1874,9 +1874,9 @@
</span><span class="cx">                  this.on( 'menu:create:playlist', this.createMenu, this );
</span><span class="cx">                  this.on( 'menu:create:video-playlist', this.createMenu, this );
</span><span class="cx">                  this.on( 'toolbar:create:main-insert', this.createToolbar, this );
</span><del>-                       this.on( 'toolbar:create:main-gallery', this.createToolbar, this );
-                       this.on( 'toolbar:create:main-playlist', this.createToolbar, this );
-                       this.on( 'toolbar:create:main-video-playlist', this.createToolbar, this );
</del><ins>+                        this.on( 'toolbar:create:main-gallery', this.createToolbar, this );
+                       this.on( 'toolbar:create:main-playlist', this.createToolbar, this );
+                       this.on( 'toolbar:create:main-video-playlist', this.createToolbar, this );
</ins><span class="cx">                   this.on( 'toolbar:create:featured-image', this.featuredImageToolbar, this );
</span><span class="cx">                  this.on( 'toolbar:create:main-embed', this.mainEmbedToolbar, this );
</span><span class="cx"> 
</span></span></pre>
</div>
</div>

</body>
</html>