diff options
author | webchick <webchick@24967.no-reply.drupal.org> | 2011-04-24 01:38:16 -0700 |
---|---|---|
committer | webchick <webchick@24967.no-reply.drupal.org> | 2011-04-24 01:38:16 -0700 |
commit | ef5ef9efc7a519f74f6bbdf8c87ba9bc16be5651 (patch) | |
tree | 4ad329820c488264a036b945ed6a81de46445469 | |
parent | 4d3217b4db094d4808fe8b0c3caea6e3b10dd575 (diff) | |
download | brdo-ef5ef9efc7a519f74f6bbdf8c87ba9bc16be5651.tar.gz brdo-ef5ef9efc7a519f74f6bbdf8c87ba9bc16be5651.tar.bz2 |
Issue #908282 by jbrown, pillarsdotnet: add width and height attributes to increase front-end performance.
-rw-r--r-- | includes/theme.inc | 6 | ||||
-rw-r--r-- | misc/watchdog-error.png | bin | 775 -> 780 bytes | |||
-rw-r--r-- | misc/watchdog-ok.png | bin | 409 -> 375 bytes | |||
-rw-r--r-- | misc/watchdog-warning.png | bin | 319 -> 318 bytes | |||
-rw-r--r-- | modules/simpletest/simpletest.pages.inc | 12 | ||||
-rw-r--r-- | modules/update/update.report.inc | 8 | ||||
-rw-r--r-- | themes/seven/template.php | 4 |
7 files changed, 15 insertions, 15 deletions
diff --git a/includes/theme.inc b/includes/theme.inc index 5325ff737..9bd706209 100644 --- a/includes/theme.inc +++ b/includes/theme.inc @@ -1760,10 +1760,10 @@ function theme_table($variables) { */ function theme_tablesort_indicator($variables) { if ($variables['style'] == "asc") { - return theme('image', array('path' => 'misc/arrow-asc.png', 'alt' => t('sort ascending'), 'title' => t('sort ascending'))); + return theme('image', array('path' => 'misc/arrow-asc.png', 'width' => 13, 'height' => 13, 'alt' => t('sort ascending'), 'title' => t('sort ascending'))); } else { - return theme('image', array('path' => 'misc/arrow-desc.png', 'alt' => t('sort descending'), 'title' => t('sort descending'))); + return theme('image', array('path' => 'misc/arrow-desc.png', 'width' => 13, 'height' => 13, 'alt' => t('sort descending'), 'title' => t('sort descending'))); } } @@ -1876,7 +1876,7 @@ function theme_more_help_link($variables) { */ function theme_feed_icon($variables) { $text = t('Subscribe to @feed-title', array('@feed-title' => $variables['title'])); - if ($image = theme('image', array('path' => 'misc/feed.png', 'alt' => $text))) { + if ($image = theme('image', array('path' => 'misc/feed.png', 'width' => 16, 'height' => 16, 'alt' => $text))) { return l($image, $variables['url'], array('html' => TRUE, 'attributes' => array('class' => array('feed-icon'), 'title' => $text))); } } diff --git a/misc/watchdog-error.png b/misc/watchdog-error.png Binary files differindex f7e60e523..db05365aa 100644 --- a/misc/watchdog-error.png +++ b/misc/watchdog-error.png diff --git a/misc/watchdog-ok.png b/misc/watchdog-ok.png Binary files differindex 6ebea3e53..1d7baa06e 100644 --- a/misc/watchdog-ok.png +++ b/misc/watchdog-ok.png diff --git a/misc/watchdog-warning.png b/misc/watchdog-warning.png Binary files differindex 5d33a512e..d8dced889 100644 --- a/misc/watchdog-warning.png +++ b/misc/watchdog-warning.png diff --git a/modules/simpletest/simpletest.pages.inc b/modules/simpletest/simpletest.pages.inc index 732d6418c..31d0b2ce7 100644 --- a/modules/simpletest/simpletest.pages.inc +++ b/modules/simpletest/simpletest.pages.inc @@ -82,8 +82,8 @@ function theme_simpletest_test_table($variables) { // Define the images used to expand/collapse the test groups. $js = array( 'images' => array( - theme('image', array('path' => 'misc/menu-collapsed.png', 'alt' => t('Expand'), 'title' => t('Expand'))) . ' <a href="#" class="simpletest-collapse">(' . t('Expand') . ')</a>', - theme('image', array('path' => 'misc/menu-expanded.png', 'alt' => t('Collapse'), 'title' => t('Collapse'))) . ' <a href="#" class="simpletest-collapse">(' . t('Collapse') . ')</a>', + theme('image', array('path' => 'misc/menu-collapsed.png', 'width' => 7, 'height' => 7, 'alt' => t('Expand'), 'title' => t('Expand'))) . ' <a href="#" class="simpletest-collapse">(' . t('Expand') . ')</a>', + theme('image', array('path' => 'misc/menu-expanded.png', 'width' => 7, 'height' => 7, 'alt' => t('Collapse'), 'title' => t('Collapse'))) . ' <a href="#" class="simpletest-collapse">(' . t('Collapse') . ')</a>', ), ); @@ -426,10 +426,10 @@ function simpletest_result_status_image($status) { if (!isset($map)) { $map = array( - 'pass' => theme('image', array('path' => 'misc/watchdog-ok.png', 'alt' => t('Pass'))), - 'fail' => theme('image', array('path' => 'misc/watchdog-error.png', 'alt' => t('Fail'))), - 'exception' => theme('image', array('path' => 'misc/watchdog-warning.png', 'alt' => t('Exception'))), - 'debug' => theme('image', array('path' => 'misc/watchdog-warning.png', 'alt' => t('Debug'))), + 'pass' => theme('image', array('path' => 'misc/watchdog-ok.png', 'width' => 18, 'height' => 18, 'alt' => t('Pass'))), + 'fail' => theme('image', array('path' => 'misc/watchdog-error.png', 'width' => 18, 'height' => 18, 'alt' => t('Fail'))), + 'exception' => theme('image', array('path' => 'misc/watchdog-warning.png', 'width' => 18, 'height' => 18, 'alt' => t('Exception'))), + 'debug' => theme('image', array('path' => 'misc/watchdog-warning.png', 'width' => 18, 'height' => 18, 'alt' => t('Debug'))), ); } if (isset($map[$status])) { diff --git a/modules/update/update.report.inc b/modules/update/update.report.inc index 8e9dbae43..3f5933acb 100644 --- a/modules/update/update.report.inc +++ b/modules/update/update.report.inc @@ -57,25 +57,25 @@ function theme_update_report($variables) { switch ($project['status']) { case UPDATE_CURRENT: $class = 'ok'; - $icon = theme('image', array('path' => 'misc/watchdog-ok.png', 'alt' => t('ok'), 'title' => t('ok'))); + $icon = theme('image', array('path' => 'misc/watchdog-ok.png', 'width' => 18, 'height' => 18, 'alt' => t('ok'), 'title' => t('ok'))); break; case UPDATE_UNKNOWN: case UPDATE_FETCH_PENDING: case UPDATE_NOT_FETCHED: $class = 'unknown'; - $icon = theme('image', array('path' => 'misc/watchdog-warning.png', 'alt' => t('warning'), 'title' => t('warning'))); + $icon = theme('image', array('path' => 'misc/watchdog-warning.png', 'width' => 18, 'height' => 18, 'alt' => t('warning'), 'title' => t('warning'))); break; case UPDATE_NOT_SECURE: case UPDATE_REVOKED: case UPDATE_NOT_SUPPORTED: $class = 'error'; - $icon = theme('image', array('path' => 'misc/watchdog-error.png', 'alt' => t('error'), 'title' => t('error'))); + $icon = theme('image', array('path' => 'misc/watchdog-error.png', 'width' => 18, 'height' => 18, 'alt' => t('error'), 'title' => t('error'))); break; case UPDATE_NOT_CHECKED: case UPDATE_NOT_CURRENT: default: $class = 'warning'; - $icon = theme('image', array('path' => 'misc/watchdog-warning.png', 'alt' => t('warning'), 'title' => t('warning'))); + $icon = theme('image', array('path' => 'misc/watchdog-warning.png', 'width' => 18, 'height' => 18, 'alt' => t('warning'), 'title' => t('warning'))); break; } diff --git a/themes/seven/template.php b/themes/seven/template.php index 5be459bea..4582749b1 100644 --- a/themes/seven/template.php +++ b/themes/seven/template.php @@ -88,10 +88,10 @@ function seven_tablesort_indicator($variables) { $style = $variables['style']; $theme_path = drupal_get_path('theme', 'seven'); if ($style == 'asc') { - return theme('image', array('path' => $theme_path . '/images/arrow-asc.png', 'alt' => t('sort ascending'), 'title' => t('sort ascending'))); + return theme('image', array('path' => $theme_path . '/images/arrow-asc.png', 'alt' => t('sort ascending'), 'width' => 13, 'height' => 13, 'title' => t('sort ascending'))); } else { - return theme('image', array('path' => $theme_path . '/images/arrow-desc.png', 'alt' => t('sort descending'), 'title' => t('sort descending'))); + return theme('image', array('path' => $theme_path . '/images/arrow-desc.png', 'alt' => t('sort descending'), 'width' => 13, 'height' => 13, 'title' => t('sort descending'))); } } |