Changeset 9596
- Timestamp:
- 03/05/2015 05:01:29 AM (11 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/bp-core/bp-core-theme-compatibility.php
r9517 r9596 165 165 */ 166 166 function bp_get_theme_compat_id() { 167 168 /** 169 * Filters the ID of the theme package being used. 170 * 171 * @since BuddyPress (1.7.0) 172 * 173 * @param string $id ID of the theme package in use. 174 */ 167 175 return apply_filters( 'bp_get_theme_compat_id', buddypress()->theme_compat->theme->id ); 168 176 } … … 181 189 */ 182 190 function bp_get_theme_compat_name() { 191 192 /** 193 * Filters the name of the theme package being used. 194 * 195 * @since BuddyPress (1.7.0) 196 * 197 * @param string $name Name of the theme package in use. 198 */ 183 199 return apply_filters( 'bp_get_theme_compat_name', buddypress()->theme_compat->theme->name ); 184 200 } … … 197 213 */ 198 214 function bp_get_theme_compat_version() { 215 216 /** 217 * Filters the version of the theme package being used. 218 * 219 * @since BuddyPress (1.7.0) 220 * 221 * @param string $version The version string of the theme package in use. 222 */ 199 223 return apply_filters( 'bp_get_theme_compat_version', buddypress()->theme_compat->theme->version ); 200 224 } … … 213 237 */ 214 238 function bp_get_theme_compat_dir() { 239 240 /** 241 * Filters the absolute path of the theme package being used. 242 * 243 * @since BuddyPress (1.7.0) 244 * 245 * @param string $dir The absolute path of the theme package in use. 246 */ 215 247 return apply_filters( 'bp_get_theme_compat_dir', buddypress()->theme_compat->theme->dir ); 216 248 } … … 230 262 */ 231 263 function bp_get_theme_compat_url() { 264 265 /** 266 * Filters the URL of the theme package being used. 267 * 268 * @since BuddyPress (1.7.0) 269 * 270 * @param string $url URL of the theme package in use. 271 */ 232 272 return apply_filters( 'bp_get_theme_compat_url', buddypress()->theme_compat->theme->url ); 233 273 } … … 250 290 } 251 291 292 /** 293 * Filters whether or not to use theme compat for the active theme. 294 * 295 * @since BuddyPress (1.9.0) 296 * 297 * @param bool $use_with_current_theme True if the current theme needs theme compatibility. 298 */ 252 299 return apply_filters( 'bp_use_theme_compat_with_current_theme', buddypress()->theme_compat->use_with_current_theme ); 253 300 } … … 407 454 * {@link BuddyPress::register_theme_packages()}. 408 455 * 409 * @since BuddyPress (1.7 )456 * @since BuddyPress (1.7.0) 410 457 * 411 458 * @see BP_Theme_Compat for a description of the $theme parameter arguments. … … 598 645 599 646 /** 647 * Fires when resetting main query vars and filtering 'the_content' to output BuddyPress template parts. 648 * 600 649 * Use this action to execute code that will communicate to BuddyPress's 601 650 * theme compatibility layer whether or not we're replacing the_content() 602 651 * with some other template part. 652 * 653 * @since BuddyPress (1.7.0) 603 654 */ 604 655 do_action( 'bp_template_include_reset_dummy_post_data' ); … … 637 688 } 638 689 690 /** 691 * Filters the template name to include. 692 * 693 * @since BuddyPress (1.7.0) 694 * 695 * @param string $template Template name. 696 */ 639 697 return apply_filters( 'bp_template_include_theme_compat', $template ); 640 698 } … … 663 721 bp_set_theme_compat_active( false ); 664 722 665 // Do we have new content to replace the old content? 723 /** 724 * Filters the content to replace in the post. 725 * 726 * @since BuddyPress (1.7.0) 727 * 728 * @param string $content Original post content. 729 */ 666 730 $new_content = apply_filters( 'bp_replace_the_content', $content ); 667 731 … … 824 888 $retval = is_buddypress() ? false : $open; 825 889 826 // Allow override of the override 890 /** 891 * Filters whether or not to force comments_status to closed for BuddyPress post types. 892 * 893 * @since BuddyPress (1.7.0) 894 * 895 * @param bool $retval Whether or not we are on a BuddyPress post type. 896 * @param bool $open True if comments open, false if closed. 897 * @param int $post_id Post ID for the checked post. 898 */ 827 899 return apply_filters( 'bp_force_comment_status', $retval, $open, $post_id ); 828 900 }
Note: See TracChangeset
for help on using the changeset viewer.