Skip to:
Content

BuddyPress.org

Changeset 9602


Ignore:
Timestamp:
03/05/2015 06:38:55 AM (7 years ago)
Author:
tw2113
Message:

Adds hooks documentation for bp-core-cssjs.php.

See #5940.

File:
1 edited

Legend:

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

    r9477 r9602  
    1818    $min = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
    1919    $url = buddypress()->plugin_url . 'bp-core/js/';
    20    
     20
     21    /**
     22     * Filters the BuddyPress Core javascript files to register.
     23     *
     24     * @since BuddyPress (2.1.0)
     25     *
     26     * @param array $value Array of javascript file information to register.
     27     */
    2128    $scripts = apply_filters( 'bp_core_register_common_scripts', array(
    2229
     
    5057    $url = buddypress()->plugin_url . 'bp-core/css/';
    5158
     59    /**
     60     * Filters the URL for the Admin Bar stylesheet.
     61     *
     62     * @since BuddyPress (1.1.0)
     63     *
     64     * @param string $value URL for the Admin Bar stylesheet.
     65     */
     66    $admin_bar_file = apply_filters( 'bp_core_admin_bar_css', "{$url}admin-bar{$min}.css" );
     67
     68    /**
     69     * Filters the BuddyPress Core stylesheet files to register.
     70     *
     71     * @since BuddyPress (2.1.0)
     72     *
     73     * @param array $value Array of stylesheet file information to register.
     74     */
    5275    $styles = apply_filters( 'bp_core_register_common_styles', array(
    5376        'bp-admin-bar' => array(
    54             'file'         => apply_filters( 'bp_core_admin_bar_css', "{$url}admin-bar{$min}.css" ),
     77            'file'         => $admin_bar_file,
    5578            'dependencies' => array( 'admin-bar' )
    5679        )
     
    102125function bp_core_add_cropper_inline_js() {
    103126
    104     // Bail if no image was uploaded
     127    /**
     128     * Filters the return value of getimagesize to determine if an image was uploaded.
     129     *
     130     * @since BuddyPress (1.1.0)
     131     *
     132     * @param array $value Array of data found by getimagesize.
     133     */
    105134    $image = apply_filters( 'bp_inline_cropper_image', getimagesize( bp_core_avatar_upload_path() . buddypress()->avatar_admin->image->dir ) );
    106135    if ( empty( $image ) ) {
     
    242271 */
    243272function bp_core_ajax_url() {
     273
     274    /**
     275     * Filters the proper value for BuddyPress' ajaxurl.
     276     *
     277     * @since BuddyPress (1.7.0)
     278     *
     279     * @param string $value Proper ajaxurl value for BuddyPress.
     280     */
    244281    return apply_filters( 'bp_core_ajax_url', admin_url( 'admin-ajax.php', is_ssl() ? 'admin' : 'http' ) );
    245282}
     
    255292 */
    256293function bp_core_get_js_dependencies() {
     294
     295    /**
     296     * Filters the javascript dependencies for buddypress.js.
     297     *
     298     * @since BuddyPress (2.0.0)
     299     *
     300     * @param array $value Array of javascript dependencies for buddypress.js.
     301     */
    257302    return apply_filters( 'bp_core_get_js_dependencies', array(
    258303        'jquery',
Note: See TracChangeset for help on using the changeset viewer.