From ab61b25214aa8107173f3451287e39629fee0be5 Mon Sep 17 00:00:00 2001 From: Nathaniel Catchpole Date: Wed, 26 Jun 2013 10:31:08 +0100 Subject: [PATCH] Issue #2024681 by jenlampton: Remove theme_meter() from core. --- core/includes/theme.inc | 46 ----------------------------------------- 1 file changed, 46 deletions(-) diff --git a/core/includes/theme.inc b/core/includes/theme.inc index 45737c5ccbc6..769a8727969d 100644 --- a/core/includes/theme.inc +++ b/core/includes/theme.inc @@ -2399,49 +2399,6 @@ function theme_progress_bar($variables) { return $output; } -/** - * Returns HTML for a meter. - * - * @param $variables - * An associative array containing: - * - display_value: The textual representation of the meter bar. - * - form: A string specifying one or more forms to which the element - * belongs separated by spaces. - * - high: A number specifying the range that is considered to be a high - * value. - * - low: A number specifying the range that is considered to be a low value. - * - max: A number specifying the maximum value of the range. - * - min: A number specifying the minimum value of the range. - * - optimum: A number specifying what value is the optimal value for the - * gauge. - * - value: A number specifying the current value of the gauge. - * - percentage: A number specifying the current percentage of the gauge. - * - attributes: Associative array of attributes to be placed in the meter - * tag. - */ -function theme_meter($variables) { - $attributes = $variables['attributes']; - - foreach (array('form', 'high', 'low', 'max', 'min', 'optimum', 'value') as $attribute) { - if (!empty($variables[$attribute])) { - // This function was initially designed for the tag, but due to - // the lack of browser and styling support for it, we're currently using - // it's attributes as HTML5 data attributes. - $attributes['data-' . $attribute] = $variables[$attribute]; - } - } - - $output = ''; - $output .= '
'; - $output .= "\n"; - - if (!empty($variables['display_value'])) { - $output .= '
' . $variables['display_value'] . '
'; - } - - return $output; -} - /** * Returns HTML for an indentation div; used for drag and drop tables. * @@ -3118,9 +3075,6 @@ function drupal_common_theme() { 'table' => array( 'variables' => array('header' => NULL, 'rows' => NULL, 'attributes' => array(), 'caption' => NULL, 'colgroups' => array(), 'sticky' => TRUE, 'responsive' => TRUE, 'empty' => ''), ), - 'meter' => array( - 'variables' => array('display_value' => NULL, 'form' => NULL, 'high' => NULL, 'low' => NULL, 'max' => NULL, 'min' => NULL, 'optimum' => NULL, 'value' => NULL, 'percentage' => NULL, 'attributes' => array()), - ), 'tablesort_indicator' => array( 'variables' => array('style' => NULL), 'template' => 'tablesort-indicator',