Index: includes/common.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/common.inc,v
retrieving revision 1.1008
diff -u -p -r1.1008 common.inc
--- includes/common.inc	5 Oct 2009 02:48:38 -0000	1.1008
+++ includes/common.inc	5 Oct 2009 22:53:48 -0000
@@ -4895,6 +4895,14 @@ function drupal_common_theme() {
     'menu_link' => array(
       'arguments' => array('element' => NULL),
     ),
+    'menu_link_icon' => array(
+      'arguments' => array(
+        'path' => NULL,
+        'menu' => NULL,
+        'alt' => '',
+        'title' => '',
+      ),
+    ),
     'menu_tree' => array(
       'arguments' => array('tree' => NULL),
     ),
Index: includes/menu.inc
===================================================================
RCS file: /cvs/drupal/drupal/includes/menu.inc,v
retrieving revision 1.348
diff -u -p -r1.348 menu.inc
--- includes/menu.inc	1 Oct 2009 19:07:12 -0000	1.348
+++ includes/menu.inc	5 Oct 2009 22:53:48 -0000
@@ -866,6 +866,7 @@ function menu_tree_output($tree) {
     $element['#attributes']['class'] = $class;
     $element['#title'] = $data['link']['title'];
     $element['#href'] = $data['link']['href'];
+    $element['#icon'] = $data['link']['icon'];
     $element['#localized_options'] = !empty($data['localized_options']) ? $data['localized_options'] : array();
     $element['#below'] = $data['below'] ? menu_tree_output($data['below']) : $data['below'];
     $element['#original_link'] = $data['link'];
@@ -940,6 +941,7 @@ function menu_tree_all_data($menu_name, 
         'title_arguments',
         'theme_callback',
         'theme_arguments',
+        'icon',
         'type',
         'description',
       ));
@@ -1123,6 +1125,7 @@ function menu_tree_page_data($menu_name,
           'title_arguments',
           'theme_callback',
           'theme_arguments',
+          'icon',
           'type',
           'description',
         ));
@@ -1329,10 +1332,46 @@ function theme_menu_link(array $element)
     $sub_menu = drupal_render($element['#below']);
   }
   $output = l($element['#title'], $element['#href'], $element['#localized_options']);
+  if (!empty($element['#icon'])) {
+    $output .= theme('menu_link_icon', $element['#icon'], $element['#original_link']['menu_name'], $element['#title'], $element['#title']);
+  }
   return '<li' . drupal_attributes($element['#attributes']) . '>' . $output . $sub_menu . "</li>\n";
 }
 
 /**
+ * Generate the HTML output for a menu link icon.
+ *
+ * @param $path
+ *   Either the path of the image file (relative to base_path()) or a full URL.
+ * @param $menu
+ *   The name of the menu that contains the link that the icon is associated
+ *   with.
+ * @param $alt
+ *   The alternative text for the icon in text-based browsers.
+ * @param $title
+ *   The title text is displayed when the image is hovered in some popular
+ *   browsers.
+ * @return
+ *   A themed HTML string representing the menu link icon.
+ *
+ * @ingroup themeable
+ */
+function theme_menu_link_icon($path, $menu, $alt = '', $title = '') {
+  $menu_icon_support = variable_get('menu_icon_support', array());
+  if (empty($menu_icon_support[$menu])) {
+    return '';
+  }
+  $menu_icon_styles = variable_get('menu_icon_styles', array());
+  if (module_exists('image') && !empty($menu_icon_styles[$menu])) {
+    $output = theme('image_style', $menu_icon_styles[$menu], $path, $alt, $title);
+  }
+  else {
+    $output = theme('image', $path, $alt, $title);
+  }
+  return $output;
+}
+
+/**
  * Generate the HTML output for a single local task link.
  *
  * @param $link
@@ -2793,6 +2832,12 @@ function _menu_router_build($callbacks) 
             $item['theme arguments'] = $parent['theme arguments'];
           }
         }
+        // Icons are also inherited from the parent item if one is not found
+        // for this specific path. This allows default icons to be specified
+        // on a per-module or per-administrative section basis.
+        if (!isset($item['icon']) && isset($parent['icon'])) {
+          $item['icon'] = $parent['icon'];
+        }
       }
     }
     if (!isset($item['access callback']) && isset($item['access arguments'])) {
@@ -2816,6 +2861,7 @@ function _menu_router_build($callbacks) 
       'title callback' => 't',
       'theme arguments' => array(),
       'theme callback' => '',
+      'icon' => '',
       'description' => '',
       'position' => '',
       'tab_parent' => '',
@@ -2867,6 +2913,7 @@ function _menu_router_save($menu, $masks
       'title_arguments',
       'theme_callback',
       'theme_arguments',
+      'icon',
       'type',
       'block_callback',
       'description',
@@ -2894,6 +2941,7 @@ function _menu_router_save($menu, $masks
       'title_arguments' => ($item['title arguments'] ? serialize($item['title arguments']) : ''),
       'theme_callback' => $item['theme callback'],
       'theme_arguments' => serialize($item['theme arguments']),
+      'icon' => $item['icon'],
       'type' => $item['type'],
       'block_callback' => $item['block callback'],
       'description' => $item['description'],
Index: modules/menu/menu.api.php
===================================================================
RCS file: /cvs/drupal/drupal/modules/menu/menu.api.php,v
retrieving revision 1.14
diff -u -p -r1.14 menu.api.php
--- modules/menu/menu.api.php	5 Oct 2009 04:36:39 -0000	1.14
+++ modules/menu/menu.api.php	5 Oct 2009 22:53:48 -0000
@@ -175,6 +175,8 @@
  *     inherited from a parent menu item.
  *   - "theme arguments": An array of arguments to pass to the theme callback
  *     function, with path component substitution as described above.
+ *   - "icon": The path to a default icon that is associated with this menu
+ *     item. If omitted, the parent menu item's icon will be used instead.
  *   - "file": A file that will be included before the callbacks are accessed;
  *     this allows callback functions to be in separate files. The file should
  *     be relative to the implementing module's directory unless otherwise
Index: modules/node/node.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/node/node.module,v
retrieving revision 1.1139
diff -u -p -r1.1139 node.module
--- modules/node/node.module	5 Oct 2009 01:18:25 -0000	1.1139
+++ modules/node/node.module	5 Oct 2009 22:53:49 -0000
@@ -1696,6 +1696,7 @@ function node_menu() {
     'page arguments' => array(1),
     'access callback' => 'node_access',
     'access arguments' => array('view', 1),
+    'icon' => 'misc/watchdog-warning.png',
     'type' => MENU_CALLBACK);
   $items['node/%node/view'] = array(
     'title' => 'View',
Index: modules/system/system.install
===================================================================
RCS file: /cvs/drupal/drupal/modules/system/system.install,v
retrieving revision 1.395
diff -u -p -r1.395 system.install
--- modules/system/system.install	5 Oct 2009 04:34:04 -0000	1.395
+++ modules/system/system.install	5 Oct 2009 22:53:49 -0000
@@ -981,6 +981,13 @@ function system_schema() {
         'not null' => TRUE,
         'default' => '',
       ),
+      'icon' => array(
+        'description' => 'The path to a default icon that is associated with this menu item.',
+        'type' => 'varchar',
+        'length' => 255,
+        'not null' => TRUE,
+        'default' => '',
+      ),
       'type' => array(
         'description' => 'Numeric representation of the type of the menu item, like MENU_LOCAL_TASK.',
         'type' => 'int',
@@ -2584,6 +2591,14 @@ function system_update_7039() {
 }
 
 /**
+ * Adds a field to the {menu_router} table to store default icons for menu
+ * items.
+ */
+function system_update_7040() {
+  db_add_field('menu_router', 'icon', array('type' => 'varchar', 'length' => 255, 'not null' => TRUE, 'default' => ''));
+}
+
+/**
  * @} End of "defgroup updates-6.x-to-7.x"
  * The next series of updates should start at 8000.
  */
Index: modules/system/system.module
===================================================================
RCS file: /cvs/drupal/drupal/modules/system/system.module,v
retrieving revision 1.801
diff -u -p -r1.801 system.module
--- modules/system/system.module	5 Oct 2009 02:43:01 -0000	1.801
+++ modules/system/system.module	5 Oct 2009 22:53:49 -0000
@@ -511,6 +511,7 @@ function system_menu() {
     'menu_name' => 'management',
     'theme callback' => 'variable_get',
     'theme arguments' => array('admin_theme'),
+    'icon' => 'misc/forum-default.png',
     'file' => 'system.admin.inc',
   );
   $items['admin/compact'] = array(
@@ -544,6 +545,7 @@ function system_menu() {
     'weight' => -8,
     'page callback' => 'system_admin_menu_block_page',
     'access arguments' => array('access administration pages'),
+    'icon' => 'misc/forum-sticky.png',
     'file' => 'system.admin.inc',
   );
   // Appearance.
@@ -555,6 +557,7 @@ function system_menu() {
     'access arguments' => array('administer site configuration'),
     'position' => 'left',
     'weight' => -6,
+    'icon' => 'misc/forum-hot-new.png',
     'file' => 'system.admin.inc',
   );
   $items['admin/appearance/select'] = array(
@@ -2746,6 +2749,29 @@ function system_image_toolkits() {
 }
 
 /**
+ * Implement hook_image_style_delete().
+ */
+function system_image_style_delete($style) {
+  // If a style is deleted, replace the style for any menus that used it for
+  // their icons with the replacement style chosen by the administrator.
+  system_image_style_save($style);
+}
+
+/**
+ * Implement hook_image_style_save().
+ */
+function system_image_style_save($style) {
+  // If a style is renamed, update any menus that used it for their icons.
+  $menu_icon_styles = variable_get('menu_icon_styles', array());
+  if (isset($style['old_name']) && ($menus = array_keys($menu_icon_styles, $style['old_name']))) {
+    foreach ($menus as $menu) {
+      $menu_icon_styles[$menu] = $style['name'];
+    }
+    variable_set('menu_icon_styles', $menu_icon_styles);
+  }
+}
+
+/**
  * Attempts to get a file using drupal_http_request and to store it locally.
  *
  * @param $url
Index: profiles/default/default.install
===================================================================
RCS file: /cvs/drupal/drupal/profiles/default/default.install,v
retrieving revision 1.8
diff -u -p -r1.8 default.install
--- profiles/default/default.install	1 Oct 2009 13:22:43 -0000	1.8
+++ profiles/default/default.install	5 Oct 2009 22:53:49 -0000
@@ -174,6 +174,9 @@ function default_install() {
   $theme_settings['toggle_comment_user_picture'] = '1';
   variable_set('theme_settings', $theme_settings);
 
+  // Enable icon support for the management menu (demo purposes only).
+  variable_set('menu_icon_support', array('management' => TRUE));
+
   // Create a default vocabulary named "Tags", enabled for the 'article' content type.
   $vocabulary = new stdClass;
   $vocabulary->name = 'Tags';
@@ -211,6 +214,7 @@ function default_install() {
     ->condition('type', 'theme')
     ->condition('name', 'seven')
     ->execute();
-  variable_set('admin_theme', 'seven');
-  variable_set('node_admin_theme', '1');
+  // Commenting this out for demo purposes only.
+  // variable_set('admin_theme', 'seven');
+  // variable_set('node_admin_theme', '1');
 }
Index: themes/garland/style.css
===================================================================
RCS file: /cvs/drupal/drupal/themes/garland/style.css,v
retrieving revision 1.65
diff -u -p -r1.65 style.css
--- themes/garland/style.css	5 Oct 2009 02:43:01 -0000	1.65
+++ themes/garland/style.css	5 Oct 2009 22:53:49 -0000
@@ -120,10 +120,6 @@ ul li.collapsed {
   list-style-image: url(images/menu-collapsed.gif); /* LTR */
 }
 
-ul li.leaf a, ul li.expanded a, ul li.collapsed a {
-  display: block;
-}
-
 ul.inline li {
   background: none;
   margin: 0;
