List Tables: Pass the `$which` parameter to `restrict_manage_posts` and `restrict_manage_users`.

`$which` contains the location of the extra table nav markup: 'top' or 'bottom'.

Props martin.krcho.
Fixes #35307.
Built from https://develop.svn.wordpress.org/trunk@37422


git-svn-id: http://core.svn.wordpress.org/trunk@37388 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Dominik Schilling 2016-05-12 15:13:27 +00:00
parent 546b031453
commit 251274abf6
3 changed files with 9 additions and 3 deletions

View File

@ -446,10 +446,13 @@ class WP_Posts_List_Table extends WP_List_Table {
*
* @since 2.1.0
* @since 4.4.0 The `$post_type` parameter was added.
* @since 4.6.0 The `$which` parameter was added.
*
* @param string $post_type The post type slug.
* @param string $which The location of the extra table nav markup:
* 'top' or 'bottom'.
*/
do_action( 'restrict_manage_posts', $this->screen->post_type );
do_action( 'restrict_manage_posts', $this->screen->post_type, $which );
submit_button( __( 'Filter' ), 'button', 'filter_action', false, array( 'id' => 'post-query-submit' ) );
}

View File

@ -275,8 +275,11 @@ class WP_Users_List_Table extends WP_List_Table {
* in the Users list table.
*
* @since 3.5.0
* @since 4.6.0 The `$which` parameter was added.
*
* @param string $which The location of the extra table nav markup: 'top' or 'bottom'.
*/
do_action( 'restrict_manage_users' );
do_action( 'restrict_manage_users', $which );
echo '</div>';
}

View File

@ -4,7 +4,7 @@
*
* @global string $wp_version
*/
$wp_version = '4.6-alpha-37421';
$wp_version = '4.6-alpha-37422';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.