Skip to:
Content

BuddyPress.org


Ignore:
Timestamp:
03/24/2011 05:26:18 AM (10 years ago)
Author:
johnjamesjacoby
Message:

This first pass at WP Admin Bar integration unhooks all WP core menus and replaces them with a full set of action based routines to handle the creation of admin bar menus at a BP component class level. This allows future external components to manipulate core menus or add their own with relative ease. Currently works off the BP_USE_WP_ADMIN_BAR constant, and should eventually phase out the BuddyBar in the long-term.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/bp-core/bp-core-hooks.php

    r3980 r4151  
    2323
    2424// Setup the navigation menu
    25 add_action( 'bp_init',    'bp_setup_nav',            8 );
     25add_action( 'bp_init',    'bp_setup_nav',            7 );
     26
     27// Setup the navigation menu
     28add_action( 'bp_init',    'bp_setup_admin_bar',      8 );
    2629
    2730// Setup the title
    28 add_action( 'bp_init',    'bp_setup_title',          8 );
     31add_action( 'bp_init',    'bp_setup_title',          9 );
    2932
    3033// Setup widgets
     
    5558function bp_setup_nav() {
    5659    do_action( 'bp_setup_nav' );
     60}
     61
     62/**
     63 * Set navigation elements
     64 */
     65function bp_setup_admin_bar() {
     66    do_action( 'bp_setup_admin_bar' );
    5767}
    5868
Note: See TracChangeset for help on using the changeset viewer.