Changeset 28989
- Timestamp:
- 07/04/2014 01:42:27 AM (12 years ago)
- File:
-
- 1 edited
-
trunk/src/wp-includes/js/media-views.js (modified) (7 diffs)
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/js/media-views.js
r28839 r28989 2141 2141 }, 2142 2142 2143 /** 2144 * Attach a selection collection to the frame. 2145 * 2146 * A selection is a collection of attachments used for a specific purpose 2147 * by a media frame. e.g. Selecting an attachment (or many) to insert into 2148 * post content. 2149 * 2150 * @see media.model.Selection 2151 */ 2143 2152 createSelection: function() { 2144 2153 var selection = this.options.selection; … … 2156 2165 }, 2157 2166 2167 /** 2168 * Create the default states on the frame. 2169 */ 2158 2170 createStates: function() { 2159 2171 var options = this.options; … … 2175 2187 }, 2176 2188 2189 /** 2190 * Bind region mode event callbacks. 2191 * 2192 * @see media.controller.Region.render 2193 */ 2177 2194 bindHandlers: function() { 2178 2195 this.on( 'router:create:browse', this.createRouter, this ); … … 2183 2200 }, 2184 2201 2185 // Routers 2186 browseRouter: function( view ) { 2187 view.set({ 2202 /** 2203 * Render callback for the router region in the `browse` mode. 2204 * 2205 * @param {wp.media.view.Router} routerView 2206 */ 2207 browseRouter: function( routerView ) { 2208 routerView.set({ 2188 2209 upload: { 2189 2210 text: l10n.uploadFilesTitle, … … 2198 2219 2199 2220 /** 2200 * Content2221 * Render callback for the content region in the `browse` mode. 2201 2222 * 2202 * @param {Object} content 2203 * @this wp.media.controller.Region 2204 */ 2205 browseContent: function( content ) { 2223 * @param {wp.media.controller.Region} contentRegion 2224 */ 2225 browseContent: function( contentRegion ) { 2206 2226 var state = this.state(); 2207 2227 … … 2209 2229 2210 2230 // Browse our library of attachments. 2211 content .view = new media.view.AttachmentsBrowser({2231 contentRegion.view = new media.view.AttachmentsBrowser({ 2212 2232 controller: this, 2213 2233 collection: state.get('library'), … … 2228 2248 2229 2249 /** 2230 * 2231 * @this wp.media.controller.Region 2250 * Render callback for the content region in the `upload` mode. 2232 2251 */ 2233 2252 uploadContent: function() { 2234 this.$el.removeClass( 'hide-toolbar');2253 this.$el.removeClass( 'hide-toolbar' ); 2235 2254 this.content.set( new media.view.UploaderInline({ 2236 2255 controller: this
Note: See TracChangeset
for help on using the changeset viewer.