Index: admin_menu.module =================================================================== RCS file: /cvs/drupal-contrib/contributions/modules/admin_menu/admin_menu.module,v retrieving revision 1.26.2.29 diff -u -p -r1.26.2.29 admin_menu.module --- admin_menu.module 10 Aug 2008 23:24:50 -0000 1.26.2.29 +++ admin_menu.module 11 Aug 2008 09:37:23 -0000 @@ -103,6 +103,13 @@ function admin_menu_theme_settings() { '#default_value' => variable_get('admin_menu_margin_top', 1), '#description' => t('If enabled, the output of this site will be shifted for approx. 20 pixels from the top of the viewport to make room for the Administration Menu. If this setting is disabled, some absolute or fixed positioned page elements at the top of the viewport may be covered by Administration Menu.'), ); + $form['admin_menu_logoff_switch_users'] = array( + '#type' => 'checkbox', + '#title' => t('Switch Users From Logoff Menu'), + '#default_value' => variable_get('admin_menu_logoff_switch_users', 1), + '#description' => t('If enabled (and access permits) there will be a list of users that an administrator can switch to when hovering over the Logoff button. If disabled, this is not displayed. On high traffic sites, the two queries used here can take a combined two seconds per page load'), + ); + $form['tweaks'] = array( '#type' => 'fieldset', '#title' => t('Drupal Administration Tweaks'), @@ -431,7 +438,7 @@ function admin_menu_form_alter($form_id, if (module_exists('devel') && !function_exists('devel_admin_menu')) { function devel_admin_menu(&$admin_menu, $may_cache) { $access_devel = user_access('access devel information'); - $access_switch = user_access('switch users'); + $access_switch = user_access('switch users') && variable_get('admin_menu_logoff_switch_users', 1); if (!$access_devel && !$access_switch) { return; }