Make WordPress Core

Ticket #19343: 19343.2.patch

File 19343.2.patch, 1.3 KB (added by GunGeekATX, 11 years ago)

Updated single_row() and inline_edit()

  • class-wp-posts-list-table.php

     
    643643                                $actions = array();
    644644                                if ( $can_edit_post && 'trash' != $post->post_status ) {
    645645                                        $actions['edit'] = '<a href="' . get_edit_post_link( $post->ID, true ) . '" title="' . esc_attr( __( 'Edit this item' ) ) . '">' . __( 'Edit' ) . '</a>';
    646                                         $actions['inline hide-if-no-js'] = '<a href="#" class="editinline" title="' . esc_attr( __( 'Edit this item inline' ) ) . '">' . __( 'Quick&nbsp;Edit' ) . '</a>';
     646                                        if ($post_type_object->show_quick_edit)
     647                                                $actions['inline hide-if-no-js'] = '<a href="#" class="editinline" title="' . esc_attr( __( 'Edit this item inline' ) ) . '">' . __( 'Quick&nbsp;Edit' ) . '</a>';
    647648                                }
    648649                                if ( current_user_can( 'delete_post', $post->ID ) ) {
    649650                                        if ( 'trash' == $post->post_status )
     
    886887                $post = get_default_post_to_edit( $screen->post_type );
    887888                $post_type_object = get_post_type_object( $screen->post_type );
    888889
     890                if (!$post_type_object->show_quick_edit)
     891                        return;
     892
    889893                $taxonomy_names = get_object_taxonomies( $screen->post_type );
    890894                $hierarchical_taxonomies = array();
    891895                $flat_taxonomies = array();