From b97bc0488491f5854a4117fc8532250c51285c67 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Wed, 17 Jul 2024 15:41:06 +0000 Subject: [PATCH] Docs: Add missing description for the `display_rows()` method in list table classes. Follow-up to [15491], [17002], [27301]. Props nikitasolanki1812, narenin, mukesh27, dd32, SergeyBiryukov. Fixes #61670. git-svn-id: https://develop.svn.wordpress.org/trunk@58745 602fd350-edb4-49c9-b593-d223f7449a82 --- src/wp-admin/includes/class-wp-links-list-table.php | 5 +++++ src/wp-admin/includes/class-wp-list-table.php | 2 +- src/wp-admin/includes/class-wp-media-list-table.php | 4 ++++ src/wp-admin/includes/class-wp-ms-sites-list-table.php | 4 +++- src/wp-admin/includes/class-wp-ms-themes-list-table.php | 3 +++ src/wp-admin/includes/class-wp-ms-users-list-table.php | 5 +++++ .../includes/class-wp-plugin-install-list-table.php | 5 +++++ src/wp-admin/includes/class-wp-plugins-list-table.php | 4 ++++ src/wp-admin/includes/class-wp-posts-list-table.php | 7 ++++++- .../includes/class-wp-theme-install-list-table.php | 3 +++ src/wp-admin/includes/class-wp-themes-list-table.php | 3 +++ 11 files changed, 42 insertions(+), 3 deletions(-) diff --git a/src/wp-admin/includes/class-wp-links-list-table.php b/src/wp-admin/includes/class-wp-links-list-table.php index 66c4990d0f7b7..b038f79a76b6c 100644 --- a/src/wp-admin/includes/class-wp-links-list-table.php +++ b/src/wp-admin/includes/class-wp-links-list-table.php @@ -307,6 +307,11 @@ public function column_default( $item, $column_name ) { do_action( 'manage_link_custom_column', $column_name, $link->link_id ); } + /** + * Generates the list table rows. + * + * @since 3.1.0 + */ public function display_rows() { foreach ( $this->items as $link ) { $link = sanitize_bookmark( $link ); diff --git a/src/wp-admin/includes/class-wp-list-table.php b/src/wp-admin/includes/class-wp-list-table.php index 2879a0a356736..253bcca800b29 100644 --- a/src/wp-admin/includes/class-wp-list-table.php +++ b/src/wp-admin/includes/class-wp-list-table.php @@ -1718,7 +1718,7 @@ public function display_rows_or_placeholder() { } /** - * Generates the table rows. + * Generates the list table rows. * * @since 3.1.0 */ diff --git a/src/wp-admin/includes/class-wp-media-list-table.php b/src/wp-admin/includes/class-wp-media-list-table.php index 02362e3a89cbb..fb0d67d7058bd 100644 --- a/src/wp-admin/includes/class-wp-media-list-table.php +++ b/src/wp-admin/includes/class-wp-media-list-table.php @@ -708,6 +708,10 @@ public function column_default( $item, $column_name ) { } /** + * Generates the list table rows. + * + * @since 3.1.0 + * * @global WP_Post $post Global post object. * @global WP_Query $wp_query WordPress Query object. */ diff --git a/src/wp-admin/includes/class-wp-ms-sites-list-table.php b/src/wp-admin/includes/class-wp-ms-sites-list-table.php index c28a454840982..19fb0e009b014 100644 --- a/src/wp-admin/includes/class-wp-ms-sites-list-table.php +++ b/src/wp-admin/includes/class-wp-ms-sites-list-table.php @@ -611,7 +611,9 @@ public function column_default( $item, $column_name ) { } /** - * @global string $mode List table view mode. + * Generates the list table rows. + * + * @since 3.1.0 */ public function display_rows() { foreach ( $this->items as $blog ) { diff --git a/src/wp-admin/includes/class-wp-ms-themes-list-table.php b/src/wp-admin/includes/class-wp-ms-themes-list-table.php index 96a1d99576cfe..372e499209b39 100644 --- a/src/wp-admin/includes/class-wp-ms-themes-list-table.php +++ b/src/wp-admin/includes/class-wp-ms-themes-list-table.php @@ -494,6 +494,9 @@ protected function get_bulk_actions() { } /** + * Generates the list table rows. + * + * @since 3.1.0 */ public function display_rows() { foreach ( $this->items as $theme ) { diff --git a/src/wp-admin/includes/class-wp-ms-users-list-table.php b/src/wp-admin/includes/class-wp-ms-users-list-table.php index d02d380536129..58d31f67f8465 100644 --- a/src/wp-admin/includes/class-wp-ms-users-list-table.php +++ b/src/wp-admin/includes/class-wp-ms-users-list-table.php @@ -470,6 +470,11 @@ public function column_default( $item, $column_name ) { echo apply_filters( 'manage_users_custom_column', '', $column_name, $user->ID ); } + /** + * Generates the list table rows. + * + * @since 3.1.0 + */ public function display_rows() { foreach ( $this->items as $user ) { $class = ''; diff --git a/src/wp-admin/includes/class-wp-plugin-install-list-table.php b/src/wp-admin/includes/class-wp-plugin-install-list-table.php index 1a318d374b583..f39ec60a24aef 100644 --- a/src/wp-admin/includes/class-wp-plugin-install-list-table.php +++ b/src/wp-admin/includes/class-wp-plugin-install-list-table.php @@ -464,6 +464,11 @@ private function order_callback( $plugin_a, $plugin_b ) { } } + /** + * Generates the list table rows. + * + * @since 3.1.0 + */ public function display_rows() { $plugins_allowedtags = array( 'a' => array( diff --git a/src/wp-admin/includes/class-wp-plugins-list-table.php b/src/wp-admin/includes/class-wp-plugins-list-table.php index b9cc969f1c599..77ae9b57d087a 100644 --- a/src/wp-admin/includes/class-wp-plugins-list-table.php +++ b/src/wp-admin/includes/class-wp-plugins-list-table.php @@ -694,6 +694,10 @@ public function current_action() { } /** + * Generates the list table rows. + * + * @since 3.1.0 + * * @global string $status */ public function display_rows() { diff --git a/src/wp-admin/includes/class-wp-posts-list-table.php b/src/wp-admin/includes/class-wp-posts-list-table.php index 826be9b67dc09..1c6ae83119a30 100644 --- a/src/wp-admin/includes/class-wp-posts-list-table.php +++ b/src/wp-admin/includes/class-wp-posts-list-table.php @@ -790,8 +790,13 @@ protected function get_sortable_columns() { } /** + * Generates the list table rows. + * + * @since 3.1.0 + * * @global WP_Query $wp_query WordPress Query object. - * @global int $per_page + * @global int $per_page + * * @param array $posts * @param int $level */ diff --git a/src/wp-admin/includes/class-wp-theme-install-list-table.php b/src/wp-admin/includes/class-wp-theme-install-list-table.php index e273d4bc81bbd..ca179b6c2d972 100644 --- a/src/wp-admin/includes/class-wp-theme-install-list-table.php +++ b/src/wp-admin/includes/class-wp-theme-install-list-table.php @@ -230,6 +230,9 @@ public function display() { } /** + * Generates the list table rows. + * + * @since 3.1.0 */ public function display_rows() { $themes = $this->items; diff --git a/src/wp-admin/includes/class-wp-themes-list-table.php b/src/wp-admin/includes/class-wp-themes-list-table.php index fce362011db3e..53b34e93f99b7 100644 --- a/src/wp-admin/includes/class-wp-themes-list-table.php +++ b/src/wp-admin/includes/class-wp-themes-list-table.php @@ -189,6 +189,9 @@ public function display_rows_or_placeholder() { } /** + * Generates the list table rows. + * + * @since 3.1.0 */ public function display_rows() { $themes = $this->items;