- Timestamp:
- 09/27/2015 05:25:02 AM (9 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-groups/classes/class-bp-group-extension.php
r10021 r10148 7 7 */ 8 8 9 // Exit if accessed directly 9 // Exit if accessed directly. 10 10 defined( 'ABSPATH' ) || exit; 11 11 … … 86 86 * @package BuddyPress 87 87 * @subpackage Groups 88 * @since BuddyPress (1.1.0)88 * @since 1.1.0 89 89 */ 90 90 class BP_Group_Extension { … … 95 95 * Information about this extension's screens. 96 96 * 97 * @since BuddyPress (1.8.0)97 * @since 1.8.0 98 98 * @access public 99 99 * @var array … … 104 104 * The name of the extending class. 105 105 * 106 * @since BuddyPress (1.8.0)106 * @since 1.8.0 107 107 * @access public 108 108 * @var string … … 113 113 * A ReflectionClass object of the current extension. 114 114 * 115 * @since BuddyPress (1.8.0)115 * @since 1.8.0 116 116 * @access public 117 117 * @var ReflectionClass … … 122 122 * Parsed configuration parameters for the extension. 123 123 * 124 * @since BuddyPress (1.8.0)124 * @since 1.8.0 125 125 * @access public 126 126 * @var array … … 131 131 * Raw config params, as passed by the extending class. 132 132 * 133 * @since BuddyPress (2.1.0)133 * @since 2.1.0 134 134 * @access public 135 135 * @var array … … 140 140 * The ID of the current group. 141 141 * 142 * @since BuddyPress (1.8.0)142 * @since 1.8.0 143 143 * @access public 144 144 * @var int … … 189 189 * Whether the current user should see the navigation item. 190 190 * 191 * @since BuddyPress (2.1.0)191 * @since 2.1.0 192 192 * @access public 193 193 * @var bool … … 198 198 * Whether the current user can visit the tab. 199 199 * 200 * @since BuddyPress (2.1.0)200 * @since 2.1.0 201 201 * @access public 202 202 * @var bool … … 237 237 * Has the extension been initialized? 238 238 * 239 * @since BuddyPress (1.8.0)239 * @since 1.8.0 240 240 * @access protected 241 241 * @var bool … … 246 246 * Extension properties as set by legacy extensions. 247 247 * 248 * @since BuddyPress (1.8.0)248 * @since 1.8.0 249 249 * @access protected 250 250 * @var array … … 258 258 * then converted to match the new format for params. 259 259 * 260 * @since BuddyPress (1.8.0)260 * @since 1.8.0 261 261 * @access protected 262 262 * @var array … … 267 267 * Redirect location as defined by post-edit save callback. 268 268 * 269 * @since BuddyPress (2.1.0)269 * @since 2.1.0 270 270 * @access protected 271 271 * @var string … … 276 276 * Miscellaneous data as set by the __set() magic method. 277 277 * 278 * @since BuddyPress (1.8.0)278 * @since 1.8.0 279 279 * @access protected 280 280 * @var array … … 334 334 * } 335 335 * 336 * @since BuddyPress (1.8.0)337 * @since BuddyPress (2.1.0)Added 'access' and 'show_tab' arguments to `$args`.336 * @since 1.8.0 337 * @since 2.1.0 Added 'access' and 'show_tab' arguments to `$args`. 338 338 * 339 339 * @param array $args { … … 416 416 * bp_register_group_extension(). 417 417 * 418 * @since BuddyPress (1.1.0)418 * @since 1.1.0 419 419 */ 420 420 public function _register() { … … 463 463 * whether your extension overrides certain callback methods. 464 464 * 465 * @since BuddyPress (1.8.0)465 * @since 1.8.0 466 466 */ 467 467 protected function setup_class_info() { … … 483 483 * - group admin 484 484 * 485 * @since BuddyPress (1.8.0)485 * @since 1.8.0 486 486 * 487 487 * @return int … … 516 516 * Gather configuration data about your screens. 517 517 * 518 * @since BuddyPress (1.8.0)518 * @since 1.8.0 519 519 * 520 520 * @return array … … 551 551 * Set up screens array based on params. 552 552 * 553 * @since BuddyPress (1.8.0)553 * @since 1.8.0 554 554 */ 555 555 protected function setup_screens() { … … 570 570 * Set up access-related settings for this extension. 571 571 * 572 * @since BuddyPress (2.1.0)572 * @since 2.1.0 573 573 */ 574 574 protected function setup_access_settings() { … … 714 714 * Hook this extension's group tab into BuddyPress, if necessary. 715 715 * 716 * @since BuddyPress (1.8.0)716 * @since 1.8.0 717 717 */ 718 718 protected function setup_display_hooks() { … … 784 784 * Filters the template to load for the main display method. 785 785 * 786 * @since BuddyPress (1.0.0)786 * @since 1.0.0 787 787 * 788 788 * @param string $template_file Path to the template to load. … … 797 797 * display() callback. 798 798 * 799 * @since BuddyPress (2.1.1)799 * @since 2.1.1 800 800 */ 801 801 public function call_display() { … … 809 809 * Access to the tab is controlled by the user_can_visit() check. 810 810 * 811 * @since BuddyPress (2.1.0)811 * @since 2.1.0 812 812 * 813 813 * @param bool $user_can_see_nav_item … … 826 826 * Determine whether the current user has access to visit this tab. 827 827 * 828 * @since BuddyPress (2.1.0)828 * @since 2.1.0 829 829 * 830 830 * @param bool $user_can_visit … … 847 847 * modified before the redirect takes place. 848 848 * 849 * @since BuddyPress (2.1.0)849 * @since 2.1.0 850 850 * 851 851 * @param bool $user_can_visit … … 876 876 * Hook this extension's Create step into BuddyPress, if necessary. 877 877 * 878 * @since BuddyPress (1.8.0)878 * @since 1.8.0 879 879 */ 880 880 protected function setup_create_hooks() { … … 904 904 * Call the create_screen() method, if we're on the right page. 905 905 * 906 * @since BuddyPress (1.8.0)906 * @since 1.8.0 907 907 */ 908 908 public function maybe_create_screen() { … … 922 922 * Call the create_screen_save() method, if we're on the right page. 923 923 * 924 * @since BuddyPress (1.8.0)924 * @since 1.8.0 925 925 */ 926 926 public function maybe_create_screen_save() { … … 938 938 * Hook this extension's Edit panel into BuddyPress, if necessary. 939 939 * 940 * @since BuddyPress (1.8.0)940 * @since 1.8.0 941 941 */ 942 942 protected function setup_edit_hooks() { … … 1012 1012 * do not auto-add our own button. 1013 1013 * 1014 * @since BuddyPress (1.8.0)1014 * @since 1.8.0 1015 1015 */ 1016 1016 public function call_edit_screen() { … … 1028 1028 * Check the nonce, and call the edit_screen_save() method. 1029 1029 * 1030 * @since BuddyPress (1.8.0)1030 * @since 1.8.0 1031 1031 */ 1032 1032 public function call_edit_screen_save() { … … 1061 1061 * Only runs if a redirect has not already occurred. 1062 1062 * 1063 * @since BuddyPress (2.1.0)1063 * @since 2.1.0 1064 1064 * 1065 1065 * @param string $value URL to redirect to. … … 1081 1081 * Hooked to 'bp_screens'. 1082 1082 * 1083 * @since BuddyPress (1.8.0)1083 * @since 1.8.0 1084 1084 * @access public So that do_action() has access. Do not call directly. 1085 1085 * … … 1100 1100 * if one is not found. 1101 1101 * 1102 * @since BuddyPress (1.8.0)1102 * @since 1.8.0 1103 1103 * 1104 1104 * @param string $screen The screen markup, captured in the output … … 1123 1123 * Does the given markup have a submit button? 1124 1124 * 1125 * @since BuddyPress (1.8.0)1125 * @since 1.8.0 1126 1126 * 1127 1127 * @param string $screen The markup to check. … … 1138 1138 * Detect redirects hardcoded into edit_screen_save() callbacks. 1139 1139 * 1140 * @since BuddyPress (2.1.0)1140 * @since 2.1.0 1141 1141 * 1142 1142 * @param string $redirect … … 1157 1157 * Hook this extension's Admin metabox into BuddyPress, if necessary. 1158 1158 * 1159 * @since BuddyPress (1.8.0)1159 * @since 1.8.0 1160 1160 */ 1161 1161 protected function setup_admin_hooks() { … … 1177 1177 * Call the admin_screen() method, and add a nonce field. 1178 1178 * 1179 * @since BuddyPress (1.8.0)1179 * @since 1.8.0 1180 1180 */ 1181 1181 public function call_admin_screen() { … … 1187 1187 * Check the nonce, and call the admin_screen_save() method. 1188 1188 * 1189 * @since BuddyPress (1.8.0)1189 * @since 1.8.0 1190 1190 */ 1191 1191 public function call_admin_screen_save() { … … 1197 1197 * Create the Dashboard meta box for this extension. 1198 1198 * 1199 * @since BuddyPress (1.7.0)1199 * @since 1.7.0 1200 1200 */ 1201 1201 public function _meta_box_display_callback() { … … 1225 1225 * must avoid name clashes. 1226 1226 * 1227 * @since BuddyPress (1.8.0)1227 * @since 1.8.0 1228 1228 * 1229 1229 * @param string $context Screen context. 'create', 'edit', or 'admin'. … … 1236 1236 * Check the nonce on a submitted settings form. 1237 1237 * 1238 * @since BuddyPress (1.8.0)1238 * @since 1.8.0 1239 1239 * 1240 1240 * @param string $context Screen context. 'create', 'edit', or 'admin'. … … 1251 1251 * must also exist and be callable. 1252 1252 * 1253 * @since BuddyPress (1.8.0)1253 * @since 1.8.0 1254 1254 * 1255 1255 * @param string $context Screen context. 'create', 'edit', or 'admin'. … … 1299 1299 * determine whether your extension has provided a given callback. 1300 1300 * 1301 * @since BuddyPress (1.8.0)1301 * @since 1.8.0 1302 1302 * 1303 1303 * @param string $context Screen context. 'create', 'edit', or 'admin'. … … 1350 1350 * https://core.trac.wordpress.org/ticket/19888 1351 1351 * 1352 * @since BuddyPress (1.8.0)1352 * @since 1.8.0 1353 1353 * 1354 1354 * @param array $a First set of arguments. … … 1395 1395 * self::setup_legacy_properties(). 1396 1396 * 1397 * @since BuddyPress (1.8.0)1397 * @since 1.8.0 1398 1398 * 1399 1399 * @param string $key Property name. … … 1420 1420 * $this->data array. 1421 1421 * 1422 * @since BuddyPress (1.8.0)1422 * @since 1.8.0 1423 1423 * 1424 1424 * @param string $key Property name. … … 1444 1444 * $this->enable_create_step. 1445 1445 * 1446 * @since BuddyPress (1.8.0)1446 * @since 1.8.0 1447 1447 * 1448 1448 * @param string $key Property name. … … 1509 1509 * object properties for configuration. Some have been moved. 1510 1510 * 1511 * @since BuddyPress (1.8.0)1511 * @since 1.8.0 1512 1512 * 1513 1513 * @return array List of legacy property keys. … … 1545 1545 * parse them into the new init() array. 1546 1546 * 1547 * @since BuddyPress (1.8.0)1547 * @since 1.8.0 1548 1548 */ 1549 1549 protected function parse_legacy_properties() { … … 1626 1626 * their old locations. 1627 1627 * 1628 * @since BuddyPress (1.8.0)1628 * @since 1.8.0 1629 1629 * 1630 1630 * @see BP_Group_Extension::__get()
Note: See TracChangeset
for help on using the changeset viewer.