From ac202e64ff2c9ce42da81ae0a892863eaa8d480e Mon Sep 17 00:00:00 2001
From: David Meister <thedavidmeister@gmail.com>
Date: Tue, 4 Jun 2013 00:13:09 +1000
Subject: [PATCH] 1828536-23

---
 core/includes/theme.inc                                     | 13 ++++++-------
 .../field/lib/Drupal/field/Plugin/views/field/Field.php     |  2 +-
 .../system/lib/Drupal/system/Tests/Theme/FunctionsTest.php  |  2 +-
 core/modules/tour/lib/Drupal/tour/TourRenderController.php  |  2 +-
 .../Drupal/views/Plugin/views/display/DisplayPluginBase.php |  2 +-
 .../lib/Drupal/views/Plugin/views/field/FieldPluginBase.php |  2 +-
 .../lib/Drupal/views/Plugin/views/field/PrerenderList.php   |  2 +-
 core/modules/views/views.theme.inc                          |  2 +-
 8 files changed, 13 insertions(+), 14 deletions(-)

diff --git a/core/includes/theme.inc b/core/includes/theme.inc
index 70cce1e..4cc0503 100644
--- a/core/includes/theme.inc
+++ b/core/includes/theme.inc
@@ -2318,7 +2318,7 @@ function template_preprocess_item_list(&$variables) {
           }
           // Lastly, inherit the original theme variables of the current list.
           $child['#theme'] = $variables['theme_hook_original'];
-          $child['#type'] = $variables['type'];
+          $child['#list_type'] = $variables['list_type'];
         }
       }
     }
@@ -2334,19 +2334,18 @@ function template_preprocess_item_list(&$variables) {
  *     render arrays. Render arrays can specify list item attributes in the
  *     #wrapper_attributes property.
  *   - title: The title of the list.
- *   - type: The type of list to return (e.g. "ul", "ol").
+ *   - list_type: The type of HTML list (e.g. "ul", "ol").
  *   - attributes: The attributes applied to the list element.
  */
 function theme_item_list($variables) {
   $items = $variables['items'];
   $title = (string) $variables['title'];
-  // @todo 'type' clashes with '#type'. Rename to 'tag'.
-  $type = $variables['type'];
+  $list_type = $variables['list_type'];
   $list_attributes = $variables['attributes'];
 
   $output = '';
   if ($items) {
-    $output .= '<' . $type . new Attribute($list_attributes) . '>';
+    $output .= '<' . $list_type . new Attribute($list_attributes) . '>';
 
     $num_items = count($items);
     $i = 0;
@@ -2368,7 +2367,7 @@ function theme_item_list($variables) {
       }
       $output .= '<li' . new Attribute($attributes) . '>' . $item . '</li>';
     }
-    $output .= "</$type>";
+    $output .= "</$list_type>";
   }
 
   // Only output the list container and title, if there are any list items.
@@ -3206,7 +3205,7 @@ function drupal_common_theme() {
       'variables' => array('type' => MARK_NEW),
     ),
     'item_list' => array(
-      'variables' => array('items' => array(), 'title' => '', 'type' => 'ul', 'attributes' => array()),
+      'variables' => array('items' => array(), 'title' => '', 'list_type' => 'ul', 'attributes' => array()),
     ),
     'more_help_link' => array(
       'variables' => array('url' => NULL),
diff --git a/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php b/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php
index 2abe98d..c529b4e 100644
--- a/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php
+++ b/core/modules/field/lib/Drupal/field/Plugin/views/field/Field.php
@@ -634,7 +634,7 @@ function render_items($items) {
           array(
             'items' => $items,
             'title' => NULL,
-            'type' => $this->options['multi_type']
+            'list_type' => $this->options['multi_type']
           ));
       }
     }
diff --git a/core/modules/system/lib/Drupal/system/Tests/Theme/FunctionsTest.php b/core/modules/system/lib/Drupal/system/Tests/Theme/FunctionsTest.php
index 1faf6d8..d8505bc 100644
--- a/core/modules/system/lib/Drupal/system/Tests/Theme/FunctionsTest.php
+++ b/core/modules/system/lib/Drupal/system/Tests/Theme/FunctionsTest.php
@@ -54,7 +54,7 @@ function testItemList() {
         'childlist' => array(
           '#theme' => 'item_list',
           '#attributes' => array('id' => 'blist'),
-          '#type' => 'ol',
+          '#list_type' => 'ol',
           '#items' => array(
             'ba',
             array(
diff --git a/core/modules/tour/lib/Drupal/tour/TourRenderController.php b/core/modules/tour/lib/Drupal/tour/TourRenderController.php
index e1bf15d..9173cdf 100644
--- a/core/modules/tour/lib/Drupal/tour/TourRenderController.php
+++ b/core/modules/tour/lib/Drupal/tour/TourRenderController.php
@@ -56,7 +56,7 @@ public function viewMultiple(array $entities = array(), $view_mode = 'full', $la
         $build[$entity_id] = array(
           '#theme' => 'item_list',
           '#items' => $list_items,
-          '#type' => 'ol',
+          '#list_type' => 'ol',
           '#attributes' => array(
             'id' => 'tour',
             'class' => array(
diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/display/DisplayPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/display/DisplayPluginBase.php
index 7f6b104..cc89a67 100644
--- a/core/modules/views/lib/Drupal/views/Plugin/views/display/DisplayPluginBase.php
+++ b/core/modules/views/lib/Drupal/views/Plugin/views/display/DisplayPluginBase.php
@@ -1698,7 +1698,7 @@ public function buildOptionsForm(&$form, &$form_state) {
               $output .= theme('item_list',
                 array(
                   'items' => $items,
-                  'type' => $type
+                  'list_type' => $type
                 ));
             }
           }
diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php b/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php
index e4501f8..77ef20b 100644
--- a/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php
+++ b/core/modules/views/lib/Drupal/views/Plugin/views/field/FieldPluginBase.php
@@ -873,7 +873,7 @@ public function buildOptionsForm(&$form, &$form_state) {
             $output .= theme('item_list',
               array(
                 'items' => $items,
-                'type' => $type
+                'list_type' => $type
               ));
           }
         }
diff --git a/core/modules/views/lib/Drupal/views/Plugin/views/field/PrerenderList.php b/core/modules/views/lib/Drupal/views/Plugin/views/field/PrerenderList.php
index 056a958..32309e7 100644
--- a/core/modules/views/lib/Drupal/views/Plugin/views/field/PrerenderList.php
+++ b/core/modules/views/lib/Drupal/views/Plugin/views/field/PrerenderList.php
@@ -83,7 +83,7 @@ function render_items($items) {
           array(
             'items' => $items,
             'title' => NULL,
-            'type' => $this->options['type']
+            'list_type' => $this->options['type']
           ));
       }
     }
diff --git a/core/modules/views/views.theme.inc b/core/modules/views/views.theme.inc
index 6b16693..09b4d1e 100644
--- a/core/modules/views/views.theme.inc
+++ b/core/modules/views/views.theme.inc
@@ -1185,7 +1185,7 @@ function theme_views_mini_pager($vars) {
     array(
       'items' => $items,
       'title' => NULL,
-      'type' => 'ul',
+      'list_type' => 'ul',
       'attributes' => array('class' => array('pager')),
     )
   );
-- 
1.7.11.1

