Ticket #28977: 28977.diff
File 28977.diff, 1.5 KB (added by , 11 years ago) |
---|
-
src/wp-includes/js/media-grid.js
285 285 'click .trash-attachment': 'trashAttachment', 286 286 'click .edit-attachment': 'editAttachment', 287 287 'click .refresh-attachment': 'refreshAttachment', 288 'click .edit-image': 'handleEditImageClick' 288 'click .edit-image': 'handleEditImageClick', 289 'click .view-attachment': 'handleViewAttachmentClick' 289 290 }, 290 291 291 292 initialize: function() { … … 307 308 this.model.on( 'sync', this.afterDelete, this ); 308 309 }, 309 310 311 /** 312 * When view is clicked, navigate to the attachment page 313 */ 314 handleViewAttachmentClick: function() { 315 window.location = this.model.get( 'link' ); 316 }, 317 310 318 preDestroy: function( event ) { 311 319 event.preventDefault(); 312 320 -
src/wp-includes/media-template.php
296 296 <# if ( 'image' === data.type && ! data.uploading ) { #> 297 297 <a class="button edit-image" href="#"><?php _e( 'Edit Image' ); ?></a> 298 298 <# } #> 299 <a class="button view-attachment" href="#"><?php _e( 'View' ); ?></a> 299 300 300 301 <# if ( ! data.uploading && data.can.remove ) { #> 301 302 <?php if ( MEDIA_TRASH ): ?>