Trimming whitespace
[squirrelmail.git] / templates / default / message_list.tpl
index 6995fb1850f5f98a4ac2466a247302a2b0af8b3a..a339efca8bde425a262ae87f41794eb985a0111e 100644 (file)
@@ -10,6 +10,7 @@
  *
  * @version $Id$
  * @package squirrelmail
+ * @subpackage templates
  */
 
 /** add required includes */
@@ -34,13 +35,13 @@ if ($pageOffset < $end_msg) {
 
 
 if (!($sort & SQSORT_THREAD) && $enablesort) {
-    $aSortSupported = array(SQM_COL_SUBJ =>     array(SQSORT_SUBJ_ASC    , SQSORT_SUBJ_DESC),
-                            SQM_COL_DATE =>     array(SQSORT_DATE_ASC    , SQSORT_DATE_DESC),
-                            SQM_COL_INT_DATE => array(SQSORT_INT_DATE_ASC, SQSORT_INT_DATE_DESC),
-                            SQM_COL_FROM =>     array(SQSORT_FROM_ASC    , SQSORT_FROM_DESC),
-                            SQM_COL_TO =>       array(SQSORT_TO_ASC      , SQSORT_TO_DESC),
-                            SQM_COL_CC =>       array(SQSORT_CC_ASC      , SQSORT_CC_DESC),
-                            SQM_COL_SIZE =>     array(SQSORT_SIZE_ASC    , SQSORT_SIZE_DESC));
+    $aSortSupported = array(SQM_COL_SUBJ =>     array(SQSORT_SUBJ_ASC     , SQSORT_SUBJ_DESC),
+                            SQM_COL_DATE =>     array(SQSORT_DATE_DESC    , SQSORT_DATE_ASC),
+                            SQM_COL_INT_DATE => array(SQSORT_INT_DATE_DESC, SQSORT_INT_DATE_ASC),
+                            SQM_COL_FROM =>     array(SQSORT_FROM_ASC     , SQSORT_FROM_DESC),
+                            SQM_COL_TO =>       array(SQSORT_TO_ASC       , SQSORT_TO_DESC),
+                            SQM_COL_CC =>       array(SQSORT_CC_ASC       , SQSORT_CC_DESC),
+                            SQM_COL_SIZE =>     array(SQSORT_SIZE_ASC     , SQSORT_SIZE_DESC));
 } else {
     $aSortSupported = array();
 }
@@ -138,16 +139,18 @@ $clickedColor = (empty($color[16])) ? $color[2] : $color[16];
         foreach ($aFormElements as $key => $value) {
             switch ($value[1]) {
             case 'submit':
-                if ($key != 'moveButton') { // add move in a different table cell
+                if ($key != 'moveButton' && $key != 'delete' && $key != 'undeleteButton') { // add move in a different table cell
 ?>
                   <input type="submit" name="<?php echo $key; ?>" value="<?php echo $value[0]; ?>" style="padding: 0px; margin: 0px;" />&nbsp;
 <?php
-            }
+                }
                 break;
             case 'checkbox':
+                if ($key != 'bypass_trash') {
 ?>
                   <input type="checkbox" name="<?php echo $key; ?>" /><?php echo $value[0]; ?>&nbsp;
 <?php
+                }
                 break;
             case 'hidden':
                  echo '<input type="hidden" name="'.$key.'" value="'. $value[0]."\">\n";
@@ -162,8 +165,31 @@ $clickedColor = (empty($color[16])) ? $color[2] : $color[16];
 
 
 <?php
+        if (isset($aFormElements['delete'])) {
+?>
+              <td align="<?php echo $align['right']; ?>">
+                <small>
+                  <input type="submit" name="delete" value="<?php echo $aFormElements['delete'][0]; ?>" style="padding: 0px; margin: 0px;" />&nbsp;
+ <?php
+            if (isset($aFormElements['bypass_trash'])) {
+?>
+                  <input type="checkbox" name="bypass_trash" /><?php echo $aFormElements['bypass_trash'][0]; ?>&nbsp;
+<?php
+            }
+            if (isset($aFormElements['undeleteButton'])) {
+?>
+                  <input type="submit" name="undeleteButton" value="<?php echo $aFormElements['undeleteButton'][0]; ?>" style="padding: 0px; margin: 0px;" />&nbsp;
+<?php
+            }
+?>
+               </small>
+              </td>
+<?php
+        } // if (isset($aFormElements['delete']))
         if (isset($aFormElements['moveButton'])) {
-?>              <small>&nbsp;
+?>
+              <td align="<?php echo $align['right']; ?>">
+                <small>&nbsp;
                   <tt>
                     <select name="targetMailbox">
                        <?php echo $aFormElements['targetMailbox'][0];?>
@@ -171,10 +197,11 @@ $clickedColor = (empty($color[16])) ? $color[2] : $color[16];
                   </tt>
                   <input type="submit" name="moveButton" value="<?php echo $aFormElements['moveButton'][0]; ?>" style="padding: 0px; margin: 0px;" />
                 </small>
+              </td>
+
 <?php
         } // if (isset($aFormElements['move']))
 ?>
-              </td>
             </tr>
           </table>
         </td>
@@ -235,14 +262,14 @@ $clickedColor = (empty($color[16])) ? $color[2] : $color[16];
           case SQM_COL_SIZE:       echo  _("Size");    break;
           case SQM_COL_PRIO:
                if ($bIcons) {
-                  echo '<img src="' . $sImageLocation. 'prio_high.png" border="0" height="10" width="5" alt="!" title="'. _("Attachment") . '" />';
+                  echo '<img src="' . $sImageLocation. 'prio_high.png" border="0" height="10" width="5" alt="!" title="'. _("Priority") . '" />';
                } else {
                   echo  '!';
                }
                break;
           case SQM_COL_ATTACHMENT:
                if ($bIcons) {
-                  echo '<img src="' . $sImageLocation. 'attach.png" border="0" height="10" width="6" alt="+" title="' . _("Priority") . '"/>';
+                  echo '<img src="' . $sImageLocation. 'attach.png" border="0" height="10" width="6" alt="+" title="' . _("Attachment") . '"/>';
                } else {
                   echo  '+';
                }
@@ -344,7 +371,8 @@ $clickedColor = (empty($color[16])) ? $color[2] : $color[16];
             switch ($aColumns[SQM_COL_PRIO]['value']) {
                 case 1:
                 case 2: $sValue .= "<font color=\"$color[1]\">!</font>"; break;
-                case 5: $sValue .= "<font color=\"$color[8]\">?</font>"; break;
+        // use downwards arrow for low priority emails
+                case 5: $sValue .= "<font color=\"$color[8]\">&#8595;</font>"; break;
                 default: break;
             }
         }
@@ -426,7 +454,7 @@ $clickedColor = (empty($color[16])) ? $color[2] : $color[16];
      */
     foreach ($aOrder as $iCol) {
         if (in_array($iCol, $show_label_columns)) {
-            $sLabelStart = '<label for="msg[' . $i . ']">';
+            $sLabelStart = '<label for="'.$form_id."_msg$i\">";
             $sLabelEnd = '</label>';
         } else {
             $sLabelStart = '';