- Timestamp:
- 05/19/2014 01:16:16 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-admin/includes/class-wp-terms-list-table.php
r28390 r28493 10 10 class WP_Terms_List_Table extends WP_List_Table { 11 11 12 var$callback_args;13 14 function __construct( $args = array() ) {12 public $callback_args; 13 14 public function __construct( $args = array() ) { 15 15 global $post_type, $taxonomy, $action, $tax; 16 16 … … 39 39 } 40 40 41 function ajax_user_can() {41 public function ajax_user_can() { 42 42 return current_user_can( get_taxonomy( $this->screen->taxonomy )->cap->manage_terms ); 43 43 } 44 44 45 function prepare_items() {45 public function prepare_items() { 46 46 $tags_per_page = $this->get_items_per_page( 'edit_' . $this->screen->taxonomy . '_per_page' ); 47 47 … … 98 98 } 99 99 100 function has_items() {100 public function has_items() { 101 101 // todo: populate $this->items in prepare_items() 102 102 return true; 103 103 } 104 104 105 function get_bulk_actions() {105 protected function get_bulk_actions() { 106 106 $actions = array(); 107 107 $actions['delete'] = __( 'Delete' ); … … 110 110 } 111 111 112 function current_action() {112 public function current_action() { 113 113 if ( isset( $_REQUEST['action'] ) && isset( $_REQUEST['delete_tags'] ) && ( 'delete' == $_REQUEST['action'] || 'delete' == $_REQUEST['action2'] ) ) 114 114 return 'bulk-delete'; … … 117 117 } 118 118 119 function get_columns() {119 protected function get_columns() { 120 120 $columns = array( 121 121 'cb' => '<input type="checkbox" />', … … 135 135 } 136 136 137 function get_sortable_columns() {137 protected function get_sortable_columns() { 138 138 return array( 139 139 'name' => 'name', … … 145 145 } 146 146 147 function display_rows_or_placeholder() {147 protected function display_rows_or_placeholder() { 148 148 $taxonomy = $this->screen->taxonomy; 149 149 … … 194 194 } 195 195 196 function _rows( $taxonomy, $terms, &$children, $start, $per_page, &$count, $parent = 0, $level = 0 ) {196 private function _rows( $taxonomy, $terms, &$children, $start, $per_page, &$count, $parent = 0, $level = 0 ) { 197 197 198 198 $end = $start + $per_page; … … 242 242 } 243 243 244 function single_row( $tag, $level = 0 ) {244 protected function single_row( $tag, $level = 0 ) { 245 245 global $taxonomy; 246 246 $tag = sanitize_term( $tag, $taxonomy ); … … 256 256 } 257 257 258 function column_cb( $tag ) {258 public function column_cb( $tag ) { 259 259 $default_term = get_option( 'default_' . $this->screen->taxonomy ); 260 260 … … 266 266 } 267 267 268 function column_name( $tag ) {268 public function column_name( $tag ) { 269 269 $taxonomy = $this->screen->taxonomy; 270 270 $tax = get_taxonomy( $taxonomy ); … … 340 340 } 341 341 342 function column_description( $tag ) {342 public function column_description( $tag ) { 343 343 return $tag->description; 344 344 } 345 345 346 function column_slug( $tag ) {346 public function column_slug( $tag ) { 347 347 /** This filter is documented in wp-admin/edit-tag-form.php */ 348 348 return apply_filters( 'editable_slug', $tag->slug ); 349 349 } 350 350 351 function column_posts( $tag ) {351 public function column_posts( $tag ) { 352 352 $count = number_format_i18n( $tag->count ); 353 353 … … 373 373 } 374 374 375 function column_links( $tag ) {375 public function column_links( $tag ) { 376 376 $count = number_format_i18n( $tag->count ); 377 377 if ( $count ) … … 380 380 } 381 381 382 function column_default( $tag, $column_name ) {382 public function column_default( $tag, $column_name ) { 383 383 /** 384 384 * Filter the displayed columns in the terms list table. … … 401 401 * @since 3.1.0 402 402 */ 403 function inline_edit() {403 public function inline_edit() { 404 404 $tax = get_taxonomy( $this->screen->taxonomy ); 405 405
Note: See TracChangeset
for help on using the changeset viewer.