Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
06/24/2024 05:29:42 PM (10 months ago)
Author:
imath
Message:

Manage BP specific WP List Tables pagination from a central function

  • Introduces bp_admin_set_screen_options() to deal with WP List Table pagination

for Activity, Groups, Opt-outs & Site Invitations.

  • Deprecates bp_activity_admin_screen_options() & bp_groups_admin_screen_options().

Props emaralive

Fixes #9195
Closes https://github.com/buddypress/buddypress/pull/320

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/bp-core/deprecated/14.0.php

    r13936 r13937  
    9999    return false;
    100100}
     101
     102/**
     103 * Handle save/update of screen options for the Activity component admin screen.
     104 *
     105 * @since 1.6.0
     106 * @deprecated 14.0.0
     107 *
     108 * @param string $value     Will always be false unless another plugin filters it first.
     109 * @param string $option    Screen option name.
     110 * @param string $new_value Screen option form value.
     111 * @return string|int Option value. False to abandon update.
     112 */
     113function bp_activity_admin_screen_options( $value, $option, $new_value ) {
     114    _deprecated_function( __FUNCTION__, '14.0.0', 'bp_admin_set_screen_options' );
     115
     116    return bp_admin_set_screen_options( $value, $option, $new_value );
     117}
     118
     119/**
     120 * Handle save/update of screen options for the Groups component admin screen.
     121 *
     122 * @since 1.7.0
     123 * @deprecated 14.0.0
     124 *
     125 * @param string $value     Will always be false unless another plugin filters it first.
     126 * @param string $option    Screen option name.
     127 * @param string $new_value Screen option form value.
     128 * @return string|int Option value. False to abandon update.
     129 */
     130function bp_groups_admin_screen_options( $value, $option, $new_value ) {
     131    _deprecated_function( __FUNCTION__, '14.0.0', 'bp_admin_set_screen_options' );
     132
     133    return bp_admin_set_screen_options( $value, $option, $new_value );
     134}
Note: See TracChangeset for help on using the changeset viewer.