Fixed bug #13097: File list: Alternating row colors are weird with thumbnails (Thanks...
authorSteffen Kamper <info@sk-typo3.de>
Fri, 8 Jan 2010 09:58:40 +0000 (09:58 +0000)
committerSteffen Kamper <info@sk-typo3.de>
Fri, 8 Jan 2010 09:58:40 +0000 (09:58 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@6734 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
typo3/class.file_list.inc

index f440c63..6ac60e1 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2010-01-08  Steffen Kamper  <info@sk-typo3.de>
+
+       * Fixed bug #13097: File list: Alternating row colors are weird with thumbnails (Thanks to Steffen Gebert)
+
 2010-01-08  Benjamin Mack  <benni@typo3.org>
 
        * Fixed bug #12779: Previously selected type of backend login is now stored in a cookie (Thanks to Sebastian Gebhard)
index 93bf4ed..c1541f7 100644 (file)
@@ -509,6 +509,20 @@ class fileList extends t3lib_recordList {
                                                        break;
                                                        case 'file':
                                                                $theData[$field] = $this->linkWrapFile($theFile[$field],$theFile['path'].$theFile['file']);
+                                                                       // Thumbsnails?
+                                                               if ($this->thumbs && $this->isImage($theFile['fileext']))       {
+                                                                       $thumbData = array();
+                                                                       $theFile_R = rawurlencode($theFile['path'].$theFile['file']);
+                                                                       $titleCol = $this->fieldArray[0];
+                       
+                                                                       $theFile_abs = $theFile['path'].$theFile['file'];
+                                                                       $check = basename($theFile_abs).':'.filemtime($theFile_abs).':'.$GLOBALS['TYPO3_CONF_VARS']['SYS']['encryptionKey'];
+                                                                       $params = '&file='.$theFile_R;
+                                                                       $params.= '&md5sum='.t3lib_div::shortMD5($check);
+                                                                       $href = $this->backPath.$this->thumbScript.'?&dummy='.$GLOBALS['EXEC_TIME'].$params;
+                       
+                                                                       $theData[$field] .= '<br /><img src="'.htmlspecialchars($href).'" hspace="2" title="'.htmlspecialchars(trim($theFile['file'])).'" alt="'.htmlspecialchars(trim($theFile['file'])).'" />';
+                                                               }
                                                        break;
                                                        default:
                                                                $theData[$field]=t3lib_div::fixed_lgd_cs($theFile[$field],$this->fixedL);
@@ -522,22 +536,6 @@ class fileList extends t3lib_recordList {
                                        }
 
                                        $out .= $this->addelement(1, $theIcon, $theData, $altRows);
-
-                                               // Thumbsnails?
-                                       if ($this->thumbs && $this->isImage($theFile['fileext']))       {
-                                               $thumbData = array();
-                                               $theFile_R = rawurlencode($theFile['path'].$theFile['file']);
-                                               $titleCol = $this->fieldArray[0];
-
-                                               $theFile_abs = $theFile['path'].$theFile['file'];
-                                               $check = basename($theFile_abs).':'.filemtime($theFile_abs).':'.$GLOBALS['TYPO3_CONF_VARS']['SYS']['encryptionKey'];
-                                               $params = '&file='.$theFile_R;
-                                               $params.= '&md5sum='.t3lib_div::shortMD5($check);
-                                               $href = $this->backPath.$this->thumbScript.'?&dummy='.$GLOBALS['EXEC_TIME'].$params;
-
-                                               $thumbData[$titleCol]='<img src="'.htmlspecialchars($href).'" hspace="2" title="'.htmlspecialchars(trim($theFile['file'])).'" alt="'.htmlspecialchars(trim($theFile['file'])).'" />';
-                                               $out.= $this->addelement(4,'',$thumbData);
-                                       }
                                }
                                $this->eCounter++;
                        }