From 583db3092e4caa441e553a05ca6daf2a80eeb4e8 Mon Sep 17 00:00:00 2001 From: stekkel Date: Sun, 17 Apr 2005 01:16:28 +0000 Subject: [PATCH] There it is, the first layout improvements in the template. If we use icons use them as well in the columnheader. git-svn-id: https://svn.code.sf.net/p/squirrelmail/code/trunk/squirrelmail@9322 7612ce4b-ef26-0410-bec9-ea0150e637f0 --- templates/default/message_list.tpl | 55 +++++++++++++++++++----------- 1 file changed, 35 insertions(+), 20 deletions(-) diff --git a/templates/default/message_list.tpl b/templates/default/message_list.tpl index 6b05b258..6995fb18 100644 --- a/templates/default/message_list.tpl +++ b/templates/default/message_list.tpl @@ -76,15 +76,23 @@ if (!($javascript_on && $fancy_index_highlite)) { } } +/** + * Check usage of images for attachments, flags and priority + */ +$bIcons = ($use_icons && $icon_theme) ? true : false; + +/** + * Location of icon images + */ +if ($bIcons) { + $sImageLocation = SM_PATH . 'images/themes/' . $icon_theme . '/'; +} + // set this to an empty string to turn off extra // highlighting of checked rows // //$clickedColor = ''; -if (!empty($color[16])) - $clickedColor = $color[16]; -else - $clickedColor = $color[2]; - +$clickedColor = (empty($color[16])) ? $color[2] : $color[16]; ?>
@@ -217,10 +225,28 @@ else case SQM_COL_FROM: echo _("From"); break; case SQM_COL_DATE: echo _("Date"); break; case SQM_COL_SUBJ: echo _("Subject"); break; - case SQM_COL_FLAGS: echo ' '; break; + case SQM_COL_FLAGS: + if ($bIcons) { + echo '!'; + } else { + echo ' '; + } + break; case SQM_COL_SIZE: echo _("Size"); break; - case SQM_COL_PRIO: echo '!'; break; - case SQM_COL_ATTACHMENT: echo '+'; break; + case SQM_COL_PRIO: + if ($bIcons) { + echo '!'; + } else { + echo '!'; + } + break; + case SQM_COL_ATTACHMENT: + if ($bIcons) { + echo '+'; + } else { + echo '+'; + } + break; case SQM_COL_INT_DATE: echo _("Received"); break; case SQM_COL_TO: echo _("To"); break; case SQM_COL_CC: echo _("Cc"); break; @@ -285,17 +311,6 @@ else $aColumns = $aMsg['columns']; - /** - * Check usage of images for attachments, flags and priority - */ - $bIcons = ($use_icons && $icon_theme) ? true : false; - - /** - * Location of icon images - */ - if ($bIcons) { - $sImageLocation = SM_PATH . 'images/themes/' . $icon_theme . '/'; - } /** * Check the flags and set a class var. @@ -456,7 +471,7 @@ else break; case SQM_COL_SIZE: case SQM_COL_FLAGS: - $sText = " "; + $sText = " "; $sText .= "$value\n"; echo $sText; break; -- 2.25.1