Index: bp-themes/bp-default/functions.php
===================================================================
--- bp-themes/bp-default/functions.php	(revision 4055)
+++ bp-themes/bp-default/functions.php	(working copy)
@@ -60,6 +60,9 @@
 	// Load the AJAX functions for the theme
 	require_once( TEMPLATEPATH . '/_inc/ajax.php' );
 
+	// This theme uses the WP Admin Bar
+	add_theme_support( 'admin-bar' );
+
 	// This theme uses post thumbnails
 	add_theme_support( 'post-thumbnails' );
 
Index: bp-themes/bp-default/_inc/css/default.css
===================================================================
--- bp-themes/bp-default/_inc/css/default.css	(revision 4055)
+++ bp-themes/bp-default/_inc/css/default.css	(working copy)
@@ -2434,4 +2434,13 @@
 
 #footer-widget-area ul.item-list li img.avatar {
 	margin-left: 15px;  /* border is 4px */
+}
+
+#wpadminbar #wp-admin-bar-my-account-with-avatar img {
+	height: 16px;
+	width: 16px;
+}
+
+#wpadminbar .quicklinks li#wp-admin-bar-my-account-with-avatar ul ul {
+	left: 0;
 }
\ No newline at end of file
Index: bp-core/bp-core-loader.php
===================================================================
--- bp-core/bp-core-loader.php	(revision 4055)
+++ bp-core/bp-core-loader.php	(working copy)
@@ -18,8 +18,8 @@
 require_once( BP_PLUGIN_DIR . '/bp-core/deprecated/1.3.php'    );
 
 // Load the WP admin bar.
-if ( !defined( 'BP_DISABLE_ADMIN_BAR' ) )
-	require_once( BP_PLUGIN_DIR . '/bp-core/bp-core-adminbar.php'  );
+if ( !defined( 'BP_DISABLE_ADMIN_BAR' ) && defined( 'BP_USE_WP_ADMIN_BAR' ) && BP_USE_WP_ADMIN_BAR )
+	require_once( BP_PLUGIN_DIR . '/bp-core/bp-core-adminbar.php' );
 
 /** "And now for something completely different" ******************************/
 
Index: bp-core/bp-core-adminbar.php
===================================================================
--- bp-core/bp-core-adminbar.php	(revision 4055)
+++ bp-core/bp-core-adminbar.php	(working copy)
@@ -1,7 +1,286 @@
 <?php
 
 /**
- * Reserved for WordPress admin bar functions
+ * BP Admin Bar
  */
+class BP_Admin_Bar {
+	var $changed_locale = false;
+	var $menu;
+	var $need_to_change_locale = false;
+	var $proto = 'http://';
+	var $user;
 
+	function initialize() {
+		WP_Admin_Bar::initialize();
+	}
+
+	function add_menu( $args = array() ) {
+		WP_Admin_Bar::add_menu( $args );
+	}
+
+	function remove_menu( $id ) {
+		WP_Admin_Bar::remove_node( $id );
+	}
+
+	function render() {
+		?>
+		<div id="wpadminbar">
+			<div class="quicklinks">
+				<ul>
+					<?php foreach ( (array) $this->menu as $id => $menu_item ) : ?>
+						<?php $this->recursive_render( $id, $menu_item ); ?>
+					<?php endforeach; ?>
+				</ul>
+			</div>
+
+			<!--
+			<div id="adminbarsearch-wrap">
+				<form action="<?php echo home_url(); ?>" method="get" id="adminbarsearch">
+					<input class="adminbar-input" name="s" id="adminbar-search" type="text" value="" maxlength="150" />
+					<input type="submit" class="adminbar-button" value="<?php _e('Search'); ?>"/>
+				</form>
+			</div>
+			-->
+		</div>
+
+		<?php
+		/* Wipe the menu, might reduce memory usage, but probably not. */
+		$this->menu = null;
+	}
+
+	function recursive_render( $id, &$menu_item ) {
+		WP_Admin_Bar::recursive_render( $id, $menu_item );
+	}
+
+	function add_node( $parent_id, &$menu, $child ) {
+		WP_Admin_Bar::add_node( $parent_id, $menu, $child );
+	}
+
+	function add_menus() {
+		add_action( 'admin_bar_menu', 'bp_admin_bar_my_account_menu',     10  );
+		add_action( 'admin_bar_menu', 'wp_admin_bar_my_sites_menu',       20  );
+		add_action( 'admin_bar_menu', 'bp_admin_bar_groups_admin_menu',   20  );
+		add_action( 'admin_bar_menu', 'bp_admin_bar_xprofile_admin_menu', 20  );
+		add_action( 'admin_bar_menu', 'wp_admin_bar_edit_menu',           30  );
+		add_action( 'admin_bar_menu', 'wp_admin_bar_shortlink_menu',      80  );
+		add_action( 'admin_bar_menu', 'wp_admin_bar_updates_menu',        70  );
+		add_action( 'admin_bar_menu', 'bp_admin_bar_random_menu',         100 );
+
+		if ( !is_network_admin() && !is_user_admin() ) {
+			add_action( 'admin_bar_menu', 'wp_admin_bar_new_content_menu', 40 );
+			add_action( 'admin_bar_menu', 'wp_admin_bar_comments_menu',    50 );
+			add_action( 'admin_bar_menu', 'wp_admin_bar_appearance_menu',  60 );
+		}
+
+		do_action( 'add_admin_bar_menus' );
+	}
+
+	function remove_node( $id, &$menu ) {
+		WP_Admin_Bar::remove_node( $id, $menu );
+	}
+
+	// TODO: Convert to a core feature for multisite or remove
+	function load_user_locale_translations() {
+		WP_Admin_Bar::load_user_locale_translations();
+	}
+
+	function unload_user_locale_translations() {
+		WP_Admin_Bar::unload_user_locale_translations();
+	}
+
+}
+add_filter( 'wp_admin_bar_class', create_function( '', "return 'BP_Admin_Bar';" ) );
+
+/**
+ * Adds the "My Account" menu to the WP Admin Bar.
+ *
+ * @since 1.3
+ *
+ * @global $bp BuddyPress
+ * @global $wp_admin_bar WP Admin Bar
+ * @uses get_current_user_id()
+ * @uses get_avatar()
+ * @uses WP_Admin_Bar::add_menu()
+ * @uses trailingslashit()
+ * @uses is_super_admin()
+ * @uses is_multisite()
+ * @uses get_dashboard_url()
+ * @uses admin_url()
+ * @uses wp_logout_url()
+ * @uses do_action() To call 'bp_admin_bar_my_account_menu' hook
+ */
+function bp_admin_bar_my_account_menu() {
+	global $bp, $wp_admin_bar, $user_identity;
+
+	$user_id = get_current_user_id();
+
+	if ( 0 != $user_id && $bp->bp_nav ) {
+		// Add the "My Account" menu
+		$avatar = get_avatar( get_current_user_id(), 16 );
+		$id = ( ! empty( $avatar ) ) ? 'my-account-with-avatar' : 'my-account';
+
+		$wp_admin_bar->add_menu( array( 'id' => $id, 'title' => $avatar . $user_identity,  'href' => trailingslashit( $bp->loggedin_user->domain . $bp->profile->slug ) ) );
+
+		// Add the "My Account" sub menus
+		$counter = 0;
+		foreach( (array) $bp->bp_nav as $key => $value ) {
+			$alt = ( 0 == $counter % 2 ) ? ' alt' : '';
+			if ( ! empty( $value['show_for_displayed_user'] ) )
+				$wp_admin_bar->add_menu( array( 'id' => $value['slug'], 'parent' => $id, 'title' => $value['name'], 'href' => trailingslashit( $value['link'] ), 'position' => $key, 'meta' => array( 'class' => $value['css_id'] . $alt ) ) );
+			$counter++;
+		}
+
+		// Add the "My Account" sub sub menus
+		$sub_counter = 0;
+		foreach( (array) $bp->bp_options_nav as $parent => $sub_menus ) {
+			foreach( (array) $sub_menus as $key => $value ) {
+				$alt = ( 0 == $sub_counter % 2 ) ? ' alt' : '';
+				if ( ! empty( $value['user_has_access'] ) )
+					$wp_admin_bar->add_menu( array( 'id' => $value['css_id'], 'parent' => $parent, 'title' => $value['name'], 'href' => trailingslashit( $value['link'] ), 'position' => $key, 'meta' => array( 'class' => $value['css_id'] . $alt ) ) );
+				$sub_counter++;
+			}
+		}
+
+		// Dashboard
+		if ( is_super_admin() && is_multisite() )
+			$wp_admin_bar->add_menu( array( 'parent' => $id, 'title' => __( 'Dashboard' ), 'href' => get_dashboard_url( $user_id ) ) );
+		elseif ( is_super_admin() )
+			$wp_admin_bar->add_menu( array( 'parent' => $id, 'title' => __( 'Dashboard' ), 'href' => admin_url() ) );
+
+		// Logout
+		$wp_admin_bar->add_menu( array( 'parent' => $id, 'title' => __( 'Log Out' ), 'href' => wp_logout_url() ) );
+	}
+
+	do_action( 'bp_admin_bar_my_account_menu' );
+}
+
+/**
+ * Adds a random item menu to the WP Admin Bar.
+ *
+ * @since 1.3
+ *
+ * @global $bp BuddyPress
+ * @global $wp_admin_bar WP Admin Bar
+ * @uses WP_Admin_Bar::add_menu()
+ * @uses trailingslashit()
+ * @uses bp_get_root_domain()
+ * @uses bp_is_active()
+ * @uses is_multisite()
+ * @uses do_action() To call 'bp_admin_bar_random_menu' hook
+ */
+function bp_admin_bar_random_menu() {
+	global $bp, $wp_admin_bar;
+
+	// Add random menu parent
+	$wp_admin_bar->add_menu( array( 'id' => 'visitrandom-menu', 'title' => __( 'Visit', 'buddypress' ), 'href' => '#', 'meta' => array( 'class' => 'align-right' ) ) );
+
+	// Add random member menu
+	$wp_admin_bar->add_menu( array( 'parent' => 'visitrandom-menu', 'title' => __( 'Random Member', 'buddypress' ), 'href' => trailingslashit( bp_get_root_domain() . '/' . $bp->members->root_slug ) . '?random-member', 'meta' => array( 'class' => 'random-member' ) ) );
+
+	// Add random group menu
+	if ( bp_is_active( 'groups' ) )
+		$wp_admin_bar->add_menu( array( 'parent' => 'visitrandom-menu', 'title' => __( 'Random Group', 'buddypress' ), 'href' => trailingslashit( bp_get_root_domain() . '/' . $bp->groups->root_slug ) . '?random-group', 'meta' => array( 'class' => 'random-group' ) ) );
+
+	// Add random blog menu
+	if ( is_multisite() && bp_is_active( 'blogs' ) )
+		$wp_admin_bar->add_menu( array( 'parent' => 'visitrandom-menu', 'title' => __( 'Random Group', 'buddypress' ), 'href' => trailingslashit( bp_get_root_domain() . '/' . $bp->blogs->root_slug ) . '?random-blog', 'meta' => array( 'class' => 'random-blog' ) ) );
+
+	do_action( 'bp_admin_bar_random_menu' );
+}
+
+/**
+ * Adds the group admin menu to the WP Admin Bar.
+ *
+ * @since 1.3
+ *
+ * @global $bp BuddyPress
+ * @global $wp_admin_bar WP Admin Bar
+ * @uses current_user_can()
+ * @uses is_super_admin()
+ * @uses WP_Admin_Bar::add_menu()
+ * @uses bp_get_groups_action_link()
+ * @uses bp_is_active()
+ * @uses do_action() To call 'bp_admin_bar_groups_admin_menu' hook
+ */
+function bp_admin_bar_groups_admin_menu() {
+	global $bp, $wp_admin_bar;
+
+	if ( empty( $bp->groups->current_group ) )
+		return false;
+
+	// Don't show this menu to non site admins or if you're viewing your own profile
+	if ( !current_user_can( 'edit_users' ) || !is_super_admin() || ( !$bp->is_item_admin && !$bp->is_item_mod ) )
+		return false;
+
+	$wp_admin_bar->add_menu( array( 'id' => 'groups-adminoptions-menu', 'title' => __( 'Group Admin', 'buddypress' ), 'href' => bp_get_groups_action_link( 'admin' ) ) );
+	$wp_admin_bar->add_menu( array( 'parent' => 'groups-adminoptions-menu', 'id'=> 'groups-admin', 'title' => __( 'Admin', 'buddypress' ), 'href' => bp_get_groups_action_link( 'admin/edit-details' ) ) );
+	$wp_admin_bar->add_menu( array( 'parent' => 'groups-admin', 'title' => __( 'Edit Details', 'buddypress' ), 'href' => bp_get_groups_action_link( 'admin/edit-details' ) ) );
+	$wp_admin_bar->add_menu( array( 'parent' => 'groups-admin', 'title' => __( 'Group Settings', 'buddypress' ), 'href' => bp_get_groups_action_link( 'admin/group-settings' ) ) );
+	$wp_admin_bar->add_menu( array( 'parent' => 'groups-admin', 'title' => __( 'Group Avatar', 'buddypress' ), 'href' => bp_get_groups_action_link( 'admin/group-avatar' ) ) );
+
+	if ( bp_is_active( 'friends' ) )
+		$wp_admin_bar->add_menu( array( 'parent' => 'groups-admin', 'title' => __( 'Manage Invitations', 'buddypress' ), 'href' => bp_get_groups_action_link( 'send-invites' ) ) );
+	$wp_admin_bar->add_menu( array( 'parent' => 'groups-admin', 'title' => __( 'Manage Members', 'buddypress' ), 'href' => bp_get_groups_action_link( 'admin/manage-members' ) ) );
+
+	if ( $bp->groups->current_group->status == 'private' )
+		$wp_admin_bar->add_menu( array( 'parent' => 'groups-admin', 'title' => __( 'Membership Requests', 'buddypress' ), 'href' => bp_get_groups_action_link( 'admin/membership-requests' ) ) );
+	$wp_admin_bar->add_menu( array( 'parent' => 'groups-admin', 'title' => __( 'Delete Group', 'buddypress' ), 'href' => bp_get_groups_action_link( 'admin/delete-group', array( 'delete-group-button' => 1, 'delete-group-understand' => 1 ), true ), 'meta' => array( 'class' => 'confirm' ) ) );
+
+	if ( bp_is_active( 'activity' ) ) {
+		$wp_admin_bar->add_menu( array( 'parent' => 'groups-adminoptions-menu', 'id'=> 'groups-activity', 'title' => __( 'Activity', 'buddypress' ), 'href' => bp_get_groups_action_link( 'activity' ) ) );
+		$wp_admin_bar->add_menu( array( 'parent' => 'groups-activity', 'title' => __( 'Activity', 'buddypress' ), 'href' => bp_get_groups_action_link( 'activity' ) ) );
+		$wp_admin_bar->add_menu( array( 'parent' => 'groups-activity', 'title' => __( 'Delete All Activity', 'buddypress' ), 'href' => bp_get_groups_action_link( 'activity/admin', array( 'clear' => 'all' ), true ), 'meta' => array( 'class' => 'confirm' ) ) );
+	}
+
+	if ( bp_is_active( 'forums' ) ) {
+		$wp_admin_bar->add_menu( array( 'parent' => 'groups-adminoptions-menu', 'id'=> 'groups-forum', 'title' => __( 'Forums', 'buddypress' ), 'href' => bp_get_groups_action_link( 'forums' ) ) );
+		$wp_admin_bar->add_menu( array( 'parent' => 'groups-forum', 'title' => __( 'Delete Forum Contents', 'buddypress' ), 'href' => bp_get_groups_action_link( 'forums/admin', array( 'clear' => 'all' ), true ), 'meta' => array( 'class' => 'confirm' ) ) );
+	}
+
+	do_action( 'bp_admin_bar_groups_admin_menu' );
+}
+
+/**
+ * Adds a random item menu to the WP Admin Bar.
+ *
+ * @since 1.3
+ *
+ * @global $bp BuddyPress
+ * @global $wp_admin_bar WP Admin Bar
+ * @uses is_super_admin()
+ * @uses bp_is_my_profile()
+ * @uses WP_Admin_Bar::add_menu()
+ * @uses esc_attr()
+ * @uses trailingslashit()
+ * @uses bp_is_active()
+ * @uses wp_nonce_url()
+ * @uses do_action() To call 'bp_admin_bar_xprofile_admin_menu' hook
+ */
+function bp_admin_bar_xprofile_admin_menu() {
+	global $bp, $wp_admin_bar;
+
+	if ( !$bp->displayed_user->id )
+		return false;
+
+	// Don't show this menu to non site admins or if you're viewing your own profile
+	if ( !is_super_admin() || bp_is_my_profile() )
+		return false;
+
+	$wp_admin_bar->add_menu( array( 'id' => 'profile-adminoptions-menu', 'title' => __( 'Admin Options', 'buddypress' ), 'href' => '' ) );
+	$wp_admin_bar->add_menu( array( 'parent' => 'profile-adminoptions-menu', 'title' => sprintf( __( "Edit %s's Profile", 'buddypress' ), esc_attr( $bp->displayed_user->fullname ) ), 'href' => trailingslashit( $bp->displayed_user->domain . $bp->profile->slug . '/edit' ) ) );
+	$wp_admin_bar->add_menu( array( 'parent' => 'profile-adminoptions-menu', 'title' => sprintf( __( "Edit %s's Avatar", 'buddypress' ), esc_attr( $bp->displayed_user->fullname ) ), 'href' => trailingslashit( $bp->displayed_user->domain . $bp->profile->slug . '/change-avatar' ) ) );
+
+	if ( bp_is_active( 'settings' ) )
+		$wp_admin_bar->add_menu( array( 'parent' => 'profile-adminoptions-menu', 'title' => sprintf( __( "Edit %s's Settings", 'buddypress' ), esc_attr( $bp->displayed_user->fullname ) ), 'href' => trailingslashit( $bp->displayed_user->domain . $bp->settings->slug . '/general' ) ) );
+
+	if ( !bp_core_is_user_spammer( $bp->displayed_user->id ) )
+		$wp_admin_bar->add_menu( array( 'parent' => 'profile-adminoptions-menu', 'title' => sprintf( __( "Mark as Spammer", 'buddypress' ), esc_attr( $bp->displayed_user->fullname ) ), 'href' => wp_nonce_url( trailingslashit( $bp->displayed_user->domain . 'admin/mark-spammer' ), 'mark-unmark-spammer' ), 'meta' => array( 'class' => 'confirm' ) ) );
+	else
+		$wp_admin_bar->add_menu( array( 'parent' => 'profile-adminoptions-menu', 'title' => sprintf( __( "Not a Spammer", 'buddypress' ), esc_attr( $bp->displayed_user->fullname ) ), 'href' => wp_nonce_url( trailingslashit( $bp->displayed_user->domain . 'admin/unmark-spammer' ), 'mark-unmark-spammer' ), 'meta' => array( 'class' => 'confirm' ) ) );
+
+	$wp_admin_bar->add_menu( array( 'parent' => 'profile-adminoptions-menu', 'title' => sprintf( __( "Delete %s", 'buddypress' ), esc_attr( $bp->displayed_user->fullname ) ), 'href' => wp_nonce_url( trailingslashit( $bp->displayed_user->domain . 'admin/delete-user' ), 'delete-user' ), 'meta' => array( 'class' => 'confirm' ) ) );
+
+	do_action( 'bp_admin_bar_xprofile_admin_menu' );
+}
+
 ?>
\ No newline at end of file
Index: bp-core/bp-core-buddybar.php
===================================================================
--- bp-core/bp-core-buddybar.php	(revision 4055)
+++ bp-core/bp-core-buddybar.php	(working copy)
@@ -446,9 +446,9 @@
 function bp_core_load_admin_bar() {
 	global $wp_version;
 
-	if ( defined( 'BP_USE_WP_ADMIN_BAR' ) && BP_USE_WP_ADMIN_BAR && $wp_version >= 3.1 ) {
-		// TODO: Add BP support to WP admin bar
-		return;
+	if ( defined( 'BP_USE_WP_ADMIN_BAR' ) && BP_USE_WP_ADMIN_BAR ) {
+		if ( !(int)get_site_option( 'hide-loggedout-adminbar' ) && !is_user_logged_in() )
+			show_admin_bar( true );
 
 	} elseif ( !defined( 'BP_DISABLE_ADMIN_BAR' ) || !BP_DISABLE_ADMIN_BAR ) {
 		// Keep the WP admin bar from loading
@@ -461,7 +461,7 @@
 			wp_enqueue_style( 'bp-admin-bar', apply_filters( 'bp_core_admin_bar_css', WP_CONTENT_URL . '/themes/' . $stylesheet . '/_inc/css/adminbar.css' ), array(), BP_VERSION );
 		else
 			wp_enqueue_style( 'bp-admin-bar', apply_filters( 'bp_core_admin_bar_css', BP_PLUGIN_URL . '/bp-themes/bp-default/_inc/css/adminbar.css' ), array(), BP_VERSION );
-		
+
 		// Actions used to build the BP admin bar
 		add_action( 'bp_adminbar_logo',  'bp_adminbar_logo' );
 		add_action( 'bp_adminbar_menus', 'bp_adminbar_login_menu',         2   );
