Ticket #25839: 25839.patch
| File 25839.patch, 2.6 KB (added by , 12 years ago) |
|---|
-
wp-admin/includes/class-wp-media-list-table.php
90 90 if ( 'top' == $which && !is_singular() && !$this->detached && !$this->is_trash ) { 91 91 $this->months_dropdown( 'attachment' ); 92 92 93 /** 94 * Fires before the filter button is rendered at the top of the attachment table 95 * 96 * @since 2.1.0 97 */ 93 98 do_action( 'restrict_manage_posts' ); 94 99 submit_button( __( 'Filter' ), 'button', false, false, array( 'id' => 'post-query-submit' ) ); 95 100 } … … 137 142 $taxonomies = get_taxonomies_for_attachments( 'objects' ); 138 143 $taxonomies = wp_filter_object_list( $taxonomies, array( 'show_admin_column' => true ), 'and', 'name' ); 139 144 145 /** 146 * Filter attachment taxonomy columns 147 * 148 * @since 3.5.0 149 * 150 * @param array $taxonomies Array of registered taxonomies for attachments 151 * @param string 'attachment' Post type 152 */ 140 153 $taxonomies = apply_filters( 'manage_taxonomies_for_attachment_columns', $taxonomies, 'attachment' ); 141 154 $taxonomies = array_filter( $taxonomies, 'taxonomy_exists' ); 142 155 … … 159 172 } 160 173 /* translators: column name */ 161 174 $posts_columns['date'] = _x( 'Date', 'column name' ); 175 176 /** 177 * Filter the columns for the media list table 178 * 179 * @since 2.5.0 180 * 181 * @param array $posts_columns Array of columns for the media table 182 * @param bool $this->detached Whether or not the table being shown contains unnatached media files 183 */ 162 184 $posts_columns = apply_filters( 'manage_media_columns', $posts_columns, $this->detached ); 163 185 164 186 return $posts_columns; … … 383 405 } 384 406 ?> 385 407 <td <?php echo $attributes ?>> 408 <?php 409 /** 410 * Fires for each custom column that has been registered using the manage_media_columns filter 411 * 412 * @since 2.5.0 413 * 414 * @param string $column_name Name of the custom column 415 * @param int $post->ID Attachment id 416 */ 417 ?> 386 418 <?php do_action( 'manage_media_custom_column', $column_name, $post->ID ); ?> 387 419 </td> 388 420 <?php … … 430 462 } 431 463 } 432 464 465 /** 466 * Filter the actions for each attachment row 467 * 468 * @since 2.8.0 469 * 470 * @param array $actions Array of actions that can be performed on each attachment 471 * @param WP_Post $post Post object 472 * @param bool $this->detached Whether or not the table being shown contains unnatached media files 473 */ 433 474 $actions = apply_filters( 'media_row_actions', $actions, $post, $this->detached ); 434 475 435 476 return $actions;