Changeset 8117
- Timestamp:
- 03/12/2014 09:26:35 PM (11 years ago)
- Location:
- trunk/bp-core
- Files:
-
- 1 added
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/bp-core/admin/bp-core-functions.php
r7827 r8117 75 75 */ 76 76 function bp_core_modify_admin_menu_highlight() { 77 global $p lugin_page, $submenu_file;77 global $pagenow, $plugin_page, $submenu_file; 78 78 79 79 // This tweaks the Settings subnav menu to show only one BuddyPress menu item 80 80 if ( ! in_array( $plugin_page, array( 'bp-activity', 'bp-general-settings', ) ) ) 81 81 $submenu_file = 'bp-components'; 82 83 // Network Admin > Tools 84 if ( in_array( $plugin_page, array( 'bp-tools', 'available-tools' ) ) ) { 85 $submenu_file = $plugin_page; 86 } 82 87 } 83 88 … … 389 394 'href' => bp_get_admin_url( add_query_arg( array( 'page' => 'bp-settings' ), 'admin.php' ) ), 390 395 'name' => __( 'Settings', 'buddypress' ) 391 ) 396 ), 392 397 ); 393 398 -
trunk/bp-core/admin/css/common.css
r7754 r8117 91 91 background-position: -61px -2px; 92 92 } 93 94 /* Tools */ 95 #adminmenu .toplevel_page_network-tools div.wp-menu-image:before { 96 content: ""; 97 } 98 93 99 th.column-gid { 94 100 width: 60px; -
trunk/bp-core/bp-core-admin.php
r7952 r8117 119 119 require( $this->admin_dir . 'bp-core-components.php' ); 120 120 require( $this->admin_dir . 'bp-core-slugs.php' ); 121 require( $this->admin_dir . 'bp-core-tools.php' ); 121 122 } 122 123 … … 153 154 // Add a link to BuddyPress About page to the admin bar 154 155 add_action( 'admin_bar_menu', array( $this, 'admin_bar_about_link' ), 15 ); 156 157 // Add a description of new BuddyPress tools in the available tools page 158 add_action( 'tool_box', 'bp_core_admin_available_tools_intro' ); 159 add_action( 'bp_network_tool_box', 'bp_core_admin_available_tools_intro' ); 155 160 156 161 /** Filters ***********************************************************/ … … 243 248 ); 244 249 250 // For consistency with non-Multisite, we add a Tools menu in 251 // the Network Admin as a home for our Tools panel 252 if ( is_multisite() && bp_core_do_network_admin() ) { 253 $tools_parent = 'network-tools'; 254 255 $hooks[] = add_menu_page( 256 __( 'Tools', 'buddypress' ), 257 __( 'Tools', 'buddypress' ), 258 'manage_network_options', 259 $tools_parent, 260 'bp_core_tools_top_level_item', 261 '', 262 24 // just above Settings 263 ); 264 265 $hooks[] = add_submenu_page( 266 $tools_parent, 267 __( 'Available Tools', 'buddypress' ), 268 __( 'Available Tools', 'buddypress' ), 269 'manage_network_options', 270 'available-tools', 271 'bp_core_admin_available_tools_page' 272 ); 273 } else { 274 $tools_parent = 'tools.php'; 275 } 276 277 $hooks[] = add_submenu_page( 278 $tools_parent, 279 __( 'BuddyPress Tools', 'buddypress' ), 280 __( 'BuddyPress', 'buddypress' ), 281 'manage_options', 282 'bp-tools', 283 'bp_core_admin_tools' 284 ); 285 245 286 // Fudge the highlighted subnav item when on a BuddyPress admin page 246 287 foreach( $hooks as $hook ) { … … 401 442 remove_submenu_page( $this->settings_page, 'bp-page-settings' ); 402 443 remove_submenu_page( $this->settings_page, 'bp-settings' ); 444 445 // Network Admin Tools 446 remove_submenu_page( 'network-tools', 'network-tools' ); 403 447 404 448 // About and Credits pages
Note: See TracChangeset
for help on using the changeset viewer.