Index: admin_menu.inc
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/admin_menu/admin_menu.inc,v
retrieving revision 1.11.2.20.2.14
diff -u -p -r1.11.2.20.2.14 admin_menu.inc
--- admin_menu.inc	6 Jul 2009 20:35:20 -0000	1.11.2.20.2.14
+++ admin_menu.inc	7 Jul 2009 23:57:58 -0000
@@ -323,3 +323,69 @@ function theme_admin_menu_icon() {
   return '<img class="admin-menu-icon" src="' . (theme_get_setting('toggle_favicon') ? theme_get_setting('favicon') : base_path() . 'misc/favicon.ico') . '" width="16" height="16" alt="' . t('Home') . '" />';
 }
 
+/**
+ * Menu callback; Provide the administration overview page.
+ *
+ * @see system_main_admin_page()
+ * @see http://drupal.org/node/513028
+ * @todo Since we already need to override it - why not also replace it with
+ *   something useful?
+ */
+function admin_menu_main_admin_page($arg = NULL) {
+  // Load system's administrative functions.
+  module_load_include('inc', 'system', 'system.admin');
+
+  // If we received an argument, they probably meant some other page.
+  // Let's 404 them since the menu system cannot be told we do not
+  // accept arguments.
+  if (isset($arg) && substr($arg, 0, 3) != 'by-') {
+    return drupal_not_found();
+  }
+
+  // Check for status report errors.
+  if (system_status(TRUE) && user_access('administer site configuration')) {
+    drupal_set_message(t('One or more problems were detected with your Drupal installation. Check the <a href="@status">status report</a> for more information.', array('@status' => url('admin/reports/status'))), 'error');
+  }
+  $blocks = array();
+  // We cannot test for link_path 'admin', because the menu system does not
+  // generate menu links for invisible items (logical).
+  if (1) {
+    // Since we do not have a plid, we can only query all admin/* links, but
+    // need to limit direct children; menu_router.fit <= 7 gives interesting
+    // results, too ;)
+    $result = db_query("
+      SELECT m.*, ml.*
+      FROM {menu_links} ml
+      INNER JOIN {menu_router} m ON ml.router_path = m.path
+      WHERE m.fit <= 3 AND ml.link_path LIKE 'admin/%%' AND ml.link_path != 'admin/help' AND hidden = 0");
+    while ($item = db_fetch_array($result)) {
+      _menu_link_translate($item);
+      if (!$item['access']) {
+        continue;
+      }
+      // The link 'description' either derived from the hook_menu 'description'
+      // or entered by the user via menu module is saved as the title attribute.
+      if (!empty($item['localized_options']['attributes']['title'])) {
+        $item['description'] = $item['localized_options']['attributes']['title'];
+      }
+      $block = $item;
+      $block['content'] = '';
+      if ($item['block_callback'] && function_exists($item['block_callback'])) {
+        $function = $item['block_callback'];
+        $block['content'] .= $function();
+      }
+      $block['content'] .= theme('admin_block_content', system_admin_menu_block($item));
+      // Prepare for sorting as in function _menu_tree_check_access().
+      // The weight is offset so it is always positive, with a uniform 5-digits.
+      $blocks[(50000 + $item['weight']) .' '. $item['title'] .' '. $item['mlid']] = $block;
+    }
+  }
+  if ($blocks) {
+    ksort($blocks);
+    return theme('admin_page', $blocks);
+  }
+  else {
+    return t('You do not have any administrative items.');
+  }
+}
+
Index: admin_menu.module
===================================================================
RCS file: /cvs/drupal-contrib/contributions/modules/admin_menu/admin_menu.module,v
retrieving revision 1.43.2.17.2.15
diff -u -p -r1.43.2.17.2.15 admin_menu.module
--- admin_menu.module	4 Jul 2009 13:48:29 -0000	1.43.2.17.2.15
+++ admin_menu.module	7 Jul 2009 23:57:03 -0000
@@ -136,6 +136,13 @@ function admin_menu_menu_alter(&$items) 
   // Remove local tasks on 'admin'.
   $items['admin/by-task']['_visible'] = FALSE;
   $items['admin/by-module']['_visible'] = FALSE;
+  // Fix core's naive 'admin/by-module' implementation.
+  $path = drupal_get_path('module', 'admin_menu');
+  foreach (array('admin', 'admin/by-module') as $callback) {
+    $items[$callback]['page callback'] = 'admin_menu_main_admin_page';
+    $items[$callback]['file'] = 'admin_menu.inc';
+    $items[$callback]['file path'] = $path;
+  }
 
   // Flush client-side caches.
   module_invoke('admin_menu', 'flush_caches');
