Added feature: #10651: Add <abbr> tag to hints SL, GL, SGL in EM
authorFrancois Suter <francois.suter@typo3.org>
Thu, 30 Apr 2009 15:05:46 +0000 (15:05 +0000)
committerFrancois Suter <francois.suter@typo3.org>
Thu, 30 Apr 2009 15:05:46 +0000 (15:05 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@5377 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
typo3/mod/tools/em/class.em_index.php
typo3/sysext/lang/locallang_common.xml
typo3/sysext/lang/locallang_mod_tools_em.xml

index c8e595f..b33ea4a 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2009-04-30  Francois Suter  <francois@typo3.org>
+
+       * Added feature: #10651: Add <abbr> tag to hints SL, GL, SGL in EM (thanks to Steffen Gebert)
+
 2009-04-29  Steffen Kamper  <info@sk-typo3.de>
 
        * Added feature #10158: Credits to coredevs
index 3c663b7..d1d3c53 100644 (file)
@@ -2923,7 +2923,36 @@ EXTENSION KEYS:
                                $cells[] = '<td nowrap="nowrap">'.
                                ($this->typePaths[$extInfo['type']] && @is_file($fileP)?'<a href="'.htmlspecialchars(t3lib_div::resolveBackPath($this->doc->backPath.'../'.$this->typePaths[$extInfo['type']].$extKey.'/doc/manual.sxw')).'" target="_blank"><img src="oodoc.gif" width="13" height="16" title="Local Open Office Manual" alt="" /></a>':'').
                                '</td>';
-                               $cells[] = '<td nowrap="nowrap">'.$this->typeLabels[$extInfo['type']].(strlen($extInfo['doubleInstall'])>1?'<strong> '.$GLOBALS['TBE_TEMPLATE']->rfw($extInfo['doubleInstall']).'</strong>':'').'</td>';
+                               
+                                       // Double installation (inclusion of an extension in more than one of system, global or local scopes)
+                               $doubleInstall = '';
+                               if (strlen($extInfo['doubleInstall']) > 1) {
+                                                                               // Separate the "SL" et al. string into an array and replace L by Local, G by Global etc.
+                                    $doubleInstallations = str_replace(
+                                        array('S', 'G', 'L'),
+                                        array($GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_mod_tools_em.xml:sysext'),
+                                              $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_mod_tools_em.xml:globalext'),
+                                              $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_mod_tools_em.xml:localext')
+                                              ),
+                                        str_split($extInfo['doubleInstall'])
+                                    );
+                                                                               // Last extension is the one actually used
+                                                                       $usedExtension = array_pop($doubleInstallations);
+                                                                               // Next extension is overridden
+                                                                       $overriddenExtensions = array_pop($doubleInstallations);
+                                                                               // If the array is not yet empty, the extension is actually installed 3 times (SGL)
+                                                                       if (count($doubleInstallations) > 0) {
+                                                                               $lastExtension = array_pop($doubleInstallations);
+                                                                               $overriddenExtensions .= ' ' . $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_common.xml:and') . ' ' . $lastExtension;
+                                                                       }
+                                    $doubleInstallTitle = sprintf(
+                                        $GLOBALS['LANG']->sL('LLL:EXT:lang/locallang_mod_tools_em.xml:double_inclusion'),
+                                        $usedExtension,
+                                        $overriddenExtensions
+                                    );
+                                    $doubleInstall = ' <strong><abbr title="' . $doubleInstallTitle .'">' . $GLOBALS['TBE_TEMPLATE']->rfw($extInfo['doubleInstall']) . '</abbr></strong>';
+                               }
+                               $cells[] = '<td nowrap="nowrap">' . $this->typeLabels[$extInfo['type']] . $doubleInstall . '</td>';
                        } else {        // Listing extensions from REMOTE repository:
                                $inst_curVer = $inst_list[$extKey]['EM_CONF']['version'];
                                if (isset($inst_list[$extKey])) {
index 19322c9..0a880a8 100644 (file)
@@ -7,6 +7,7 @@
        <data type="array">
                <languageKey index="default" type="array">
                        <label index="about">About</label>
+                       <label index="and">and</label>
                        <label index="ascending">Ascending</label>
                        <label index="back">Back</label>
                        <label index="byteSizeUnits"> B| KB| MB| GB</label>
index f3896df..18bfe1e 100755 (executable)
                        <label index="msg_modified">Modified Files:</label>
                        <label index="note_last_update">Last update of list of extensions:</label>
                        <label index="note_last_update2">Use "Retrieve/Update" in "Import Extensions" section to get/update the list.</label>
+                       <label index="double_inclusion">%1$s takes precedence over %2$s</label>
+                       <label index="globalext">Globally installed extension</label>
+                       <label index="localext">Locally installed extension</label>
+                       <label index="sysext">System extension</label>
                </languageKey>
        </data>
 </T3locallang>