[TASK] Replace sprite icon "actions-document-new" with the new IconFactory 60/42360/2
authorMarkus Guenther <mail@markus-guenther.de>
Fri, 7 Aug 2015 07:50:09 +0000 (09:50 +0200)
committerFrank Nägler <frank.naegler@typo3.org>
Fri, 7 Aug 2015 10:17:24 +0000 (12:17 +0200)
Replaces all IconUtility::getSpriteIcon calls for the icon
actions-document-new with the new IconFactory.

Resolves: #68806
Releases: master
Change-Id: I6b69742494c2b16f499ce6367ccf5b689f958bad
Reviewed-on: http://review.typo3.org/42360
Reviewed-by: Frank Nägler <frank.naegler@typo3.org>
Tested-by: Frank Nägler <frank.naegler@typo3.org>
Reviewed-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring <aleichsenring@ab-softlab.de>
18 files changed:
Build/Resources/Public/Less/Component/icon.less
typo3/sysext/backend/Classes/ClickMenu/ClickMenu.php
typo3/sysext/backend/Classes/Controller/NewRecordController.php
typo3/sysext/backend/Classes/Form/Container/FlexFormSectionContainer.php
typo3/sysext/backend/Classes/Form/Container/InlineControlContainer.php
typo3/sysext/backend/Classes/View/PageLayoutView.php
typo3/sysext/beuser/Resources/Private/Templates/BackendUser/Index.html
typo3/sysext/beuser/Resources/Private/Templates/BackendUserGroup/Index.html
typo3/sysext/core/Classes/Imaging/IconRegistry.php
typo3/sysext/feedit/Classes/FrontendEditPanel.php
typo3/sysext/filelist/Classes/Controller/FileListController.php
typo3/sysext/frontend/Classes/Controller/TranslationStatusController.php
typo3/sysext/frontend/Classes/View/AdminPanelView.php
typo3/sysext/recordlist/Classes/RecordList/DatabaseRecordList.php
typo3/sysext/scheduler/Classes/Controller/SchedulerModuleController.php
typo3/sysext/sys_action/Classes/ActionTask.php
typo3/sysext/t3skin/Resources/Public/Css/backend.css
typo3/sysext/tstemplate/Classes/Controller/TypoScriptTemplateModuleController.php

index e0d9a05..bc6f3a7 100644 (file)
@@ -26,7 +26,6 @@
 @icon-size-large:        48px;
 @icon-unify-modifier:    0.86;
 
-
 //
 // Component
 //
@@ -34,6 +33,8 @@
        position: relative;
        display: inline-block;
        overflow: hidden;
+       vertical-align: middle;
+       white-space: nowrap;
        img {
                display: block;
                height: 100%;
 }
 .icon-markup {
        position: absolute;
-       height: 100%;
-       width: 100%;
+       display: block;
        text-align: center;
+       top: 0;
+       left: 0;
+       right: 0;
+       bottom: 0;
 }
 .icon-overlay {
        position: absolute;
        bottom: 0;
        right: 0;
-       height: 50%;
-       width: 50%;
+       height: 60%;
+       width: 60%;
        text-align: center;
 }
+.icon-unify {
+       display: block;
+}
 
 //
 // Variants
        .icon-size-@{identifier} {
                height: @size;
                width: @size;
+               line-height: @size;
                .icon-unify {
                        line-height: @size;
                        font-size: ceil(@size * @icon-unify-modifier);
                }
                .icon-overlay {
                        .icon-unify {
-                               line-height: ceil(@size / 2);
-                               font-size: ceil(ceil(@size / 2) * @icon-unify-modifier);
+                               line-height: ceil(@size / 1.6);
+                               font-size: ceil(ceil(@size / 1.6) * @icon-unify-modifier);
                        }
                }
        }
index dde3e2d..617b5a0 100644 (file)
@@ -152,9 +152,9 @@ class ClickMenu {
         * @param BackendUserAuthentication $backendUser
         */
        public function __construct(LanguageService $languageService = NULL, BackendUserAuthentication $backendUser = NULL) {
-                       $this->languageService = $languageService ?: $GLOBALS['LANG'];
-                       $this->backendUser = $backendUser ?: $GLOBALS['BE_USER'];
-               }
+               $this->languageService = $languageService ?: $GLOBALS['LANG'];
+               $this->backendUser = $backendUser ?: $GLOBALS['BE_USER'];
+       }
 
        /**
         * Initialize click menu
index 8f46cea..5af9e4a 100644 (file)
@@ -17,6 +17,8 @@ namespace TYPO3\CMS\Backend\Controller;
 use TYPO3\CMS\Backend\Utility\BackendUtility;
 use TYPO3\CMS\Backend\Utility\IconUtility;
 use TYPO3\CMS\Core\Database\DatabaseConnection;
+use TYPO3\CMS\Core\Imaging\Icon;
+use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Utility\ExtensionManagementUtility;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 use TYPO3\CMS\Backend\Template\DocumentTemplate;
@@ -351,6 +353,8 @@ class NewRecordController {
         * @return void
         */
        public function regularNew() {
+               /** @var IconFactory $iconFactory */
+               $iconFactory = GeneralUtility::makeInstance(IconFactory::class);
                $lang = $this->getLanguageService();
                // Initialize array for accumulating table rows:
                $this->tRows = array();
@@ -404,7 +408,7 @@ class NewRecordController {
                $iconFile = array();
                // New tables (but not pages) INSIDE this pages
                $isAdmin = $this->getBackendUserAuthentication()->isAdmin();
-               $newContentIcon = IconUtility::getSpriteIcon('actions-document-new');
+               $newContentIcon = $iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL);
                if ($this->newContentInto) {
                        if (is_array($GLOBALS['TCA'])) {
                                $groupName = '';
index 503a775..8b52bdc 100644 (file)
@@ -15,6 +15,8 @@ namespace TYPO3\CMS\Backend\Form\Container;
  */
 
 use TYPO3\CMS\Backend\Utility\IconUtility;
+use TYPO3\CMS\Core\Imaging\Icon;
+use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 use TYPO3\CMS\Core\Authentication\BackendUserAuthentication;
 use TYPO3\CMS\Lang\LanguageService;
@@ -36,6 +38,8 @@ class FlexFormSectionContainer extends AbstractContainer {
         * @return array As defined in initializeResultArray() of AbstractNode
         */
        public function render() {
+               /** @var IconFactory $iconFactory */
+               $iconFactory = GeneralUtility::makeInstance(IconFactory::class);
                $languageService = $this->getLanguageService();
 
                $flexFormFieldsArray = $this->globalOptions['flexFormDataStructureArray'];
@@ -124,7 +128,7 @@ class FlexFormSectionContainer extends AbstractContainer {
                        $onClickInsert[] = 'return false;';
 
                        $containerTemplateHtml[] = '<a href="#" onclick="' . htmlspecialchars(implode(LF, $onClickInsert)) . '">';
-                       $containerTemplateHtml[] =      IconUtility::getSpriteIcon('actions-document-new');
+                       $containerTemplateHtml[] =      $iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL);
                        $containerTemplateHtml[] =      htmlspecialchars(GeneralUtility::fixed_lgd_cs($sectionTitle, 30));
                        $containerTemplateHtml[] = '</a>';
                        $containerTemplatesHtml[] = implode(LF, $containerTemplateHtml);
index a193333..26e6fcc 100644 (file)
@@ -15,6 +15,8 @@ namespace TYPO3\CMS\Backend\Form\Container;
  */
 
 use TYPO3\CMS\Backend\Utility\BackendUtility;
+use TYPO3\CMS\Core\Imaging\Icon;
+use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Resource\Folder;
 use TYPO3\CMS\Core\Utility\MathUtility;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
@@ -55,6 +57,18 @@ class InlineControlContainer extends AbstractContainer {
        protected $inlineStackProcessor;
 
        /**
+        * @var IconFactory
+        */
+       protected $iconFactory;
+
+       /**
+        * Construct to initialize class variables.
+        */
+       public function __construct() {
+               $this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);
+       }
+
+       /**
         * Entry method
         *
         * @return array As defined in initializeResultArray() of AbstractNode
@@ -638,8 +652,8 @@ class InlineControlContainer extends AbstractContainer {
                                }
                                $item .= '
                                <span class="input-group-btn">
-                                       <a href="#" class="btn btn-default" onclick="' . htmlspecialchars($onChange) . '">
-                                               ' . IconUtility::getSpriteIcon('actions-document-new', array('title' => $createNewRelationText)) . $createNewRelationText . '
+                                       <a href="#" class="btn btn-default" onclick="' . htmlspecialchars($onChange) . '" . title="' . $createNewRelationText .'">
+                                               ' . $this->iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL) . $createNewRelationText . '
                                        </a>
                                </span>';
                        } else {
index 15313ad..9d6a4cd 100644 (file)
@@ -19,6 +19,8 @@ use TYPO3\CMS\Backend\Utility\BackendUtility;
 use TYPO3\CMS\Backend\Utility\IconUtility;
 use TYPO3\CMS\Core\Authentication\BackendUserAuthentication;
 use TYPO3\CMS\Core\Database\DatabaseConnection;
+use TYPO3\CMS\Core\Imaging\Icon;
+use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Messaging\FlashMessage;
 use TYPO3\CMS\Core\Page\PageRenderer;
 use TYPO3\CMS\Core\Type\Bitmask\Permission;
@@ -170,6 +172,18 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
         */
        public $ext_CALC_PERMS;
 
+       /**
+        * @var IconFactory
+        */
+       protected $iconFactory;
+
+       /**
+        * Construct to initialize class variables.
+        */
+       public function __construct() {
+               $this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);
+       }
+
        /*****************************************
         *
         * Renderings
@@ -453,7 +467,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                                if ($this->getPageLayoutController()->pageIsNotLockedForEditors()) {
                                        $link = '<a href="#" onclick="' . htmlspecialchars($this->newContentElementOnClick($id, $key, $lP))
                                                . '" title="' . $this->getLanguageService()->getLL('newContentElement', TRUE) . '" class="btn btn-default btn-sm">'
-                                               . IconUtility::getSpriteIcon('actions-document-new')
+                                               . $this->iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL)
                                                . ' '
                                                . $this->getLanguageService()->getLL('content', TRUE) . '</a>';
                                }
@@ -528,7 +542,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                                                        $singleElementHTML .= '
                                                                <a href="#" onclick="' . htmlspecialchars($onClick) . '" title="'
                                                                        . $this->getLanguageService()->getLL('newContentElement', TRUE) . '" class="btn btn-default btn-sm">'
-                                                                       . IconUtility::getSpriteIcon('actions-document-new')
+                                                                       . $this->iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL)
                                                                        . ' '
                                                                        . $this->getLanguageService()->getLL('content', TRUE) . '</a>
                                                        ';
@@ -788,7 +802,7 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                        $onClick = BackendUtility::editOnClick('&edit[' . $table . '][' . $this->id . ']=new');
                        $theData['__cmds__'] = '<a href="#" onclick="' . htmlspecialchars($onClick) . '" '
                                . 'title="' . $this->getLanguageService()->getLL('new', TRUE) . '">'
-                               . IconUtility::getSpriteIcon('actions-document-new') . '</a>';
+                               . $this->iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL) . '</a>';
                }
                $out .= $this->addelement(1, '', $theData, ' class="c-headLine"', 15, '', 'th');
                // Render Items
index fa6a577..c4f9c6c 100644 (file)
@@ -1,10 +1,11 @@
 {namespace be = TYPO3\CMS\Backend\ViewHelpers}
 {namespace bu = TYPO3\CMS\Beuser\ViewHelpers}
+{namespace core = TYPO3\CMS\Core\ViewHelpers}
 
 <f:layout name="Default" />
 
 <f:section name="iconButtons">
-       <a href="{bu:editRecord(parameters: 'edit[be_users][0]=new&returnUrl={returnUrl}')}"><be:spriteManagerIcon iconName="actions-document-new" /></a>
+       <a href="{bu:editRecord(parameters: 'edit[be_users][0]=new&returnUrl={returnUrl}')}"><core:icon identifier="actions-document-new" /></a>
 </f:section>
 
 <f:section name="headline">
index 0403766..e1448e1 100644 (file)
@@ -1,10 +1,11 @@
 {namespace be = TYPO3\CMS\Backend\ViewHelpers}
 {namespace bu = TYPO3\CMS\Beuser\ViewHelpers}
+{namespace core = TYPO3\CMS\Core\ViewHelpers}
 
 <f:layout name="Default" />
 
 <f:section name="iconButtons">
-       <a href="{bu:editRecord(parameters: 'edit[be_groups][0]=new&returnUrl={returnUrl}')}"><be:spriteManagerIcon iconName="actions-document-new" /></a>
+       <a href="{bu:editRecord(parameters: 'edit[be_groups][0]=new&returnUrl={returnUrl}')}"><core:icon identifier="actions-document-new" /></a>
 </f:section>
 
 <f:section name="headline">
index a7598b0..1669be2 100644 (file)
@@ -68,6 +68,13 @@ class IconRegistry implements \TYPO3\CMS\Core\SingletonInterface {
                                'name' => 'arrows',
                        )
                ),
+
+               'actions-document-new' => array(
+                       'provider' => FontawesomeIconProvider::class,
+                       'options' => array(
+                               'name' => 'plus-square',
+                       )
+               ),
                'actions-document-open' => array(
                        'provider' => FontawesomeIconProvider::class,
                        'options' => array(
@@ -115,7 +122,7 @@ class IconRegistry implements \TYPO3\CMS\Core\SingletonInterface {
         * @throws \InvalidArgumentException
         */
        public function registerIcon($identifier, $iconProviderClassName, array $options = array()) {
-               if (!in_array(IconProviderInterface::class, class_implements($iconProviderClassName))) {
+               if (!in_array(IconProviderInterface::class, class_implements($iconProviderClassName), TRUE)) {
                        throw new \InvalidArgumentException('An IconProvider must implement ' . IconProviderInterface::class, 1437425803);
                }
                $this->icons[$identifier] = array(
index f36bbbc..3ee431c 100644 (file)
@@ -316,4 +316,4 @@ class FrontendEditPanel {
                return $status;
        }
 
-}
\ No newline at end of file
+}
index f1aa7ec..ed26779 100644 (file)
@@ -17,6 +17,8 @@ namespace TYPO3\CMS\Filelist\Controller;
 use TYPO3\CMS\Backend\Template\DocumentTemplate;
 use TYPO3\CMS\Backend\Utility\BackendUtility;
 use TYPO3\CMS\Backend\Utility\IconUtility;
+use TYPO3\CMS\Core\Imaging\Icon;
+use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Messaging\FlashMessage;
 use TYPO3\CMS\Core\Page\PageRenderer;
 use TYPO3\CMS\Core\Resource\Exception;
@@ -497,6 +499,9 @@ class FileListController {
         * @return array All available buttons as an assoc. array
         */
        public function getButtons() {
+               /** @var IconFactory $iconFactory */
+               $iconFactory = GeneralUtility::makeInstance(IconFactory::class);
+
                $buttons = array(
                        'csh' => '',
                        'shortcut' => '',
@@ -531,7 +536,7 @@ class FileListController {
                                                'target' => $this->folderObject->getCombinedIdentifier(),
                                                'returnUrl' => $this->filelist->listURL(),
                                        )
-                               )) . '" title="' . $this->getLanguageService()->makeEntities($this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:cm.new', TRUE)) . '">' . IconUtility::getSpriteIcon('actions-document-new') . '</a>';
+                               )) . '" title="' . $this->getLanguageService()->makeEntities($this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:cm.new', TRUE)) . '">' . $iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL) . '</a>';
                }
                return $buttons;
        }
index 958facf..cc368be 100644 (file)
@@ -1,4 +1,5 @@
 <?php
+
 namespace TYPO3\CMS\Frontend\Controller;
 
 /*
@@ -17,6 +18,8 @@ namespace TYPO3\CMS\Frontend\Controller;
 use TYPO3\CMS\Backend\Tree\View\PageTreeView;
 use TYPO3\CMS\Backend\Utility\BackendUtility;
 use TYPO3\CMS\Backend\Utility\IconUtility;
+use TYPO3\CMS\Core\Imaging\Icon;
+use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 
 /**
@@ -25,6 +28,18 @@ use TYPO3\CMS\Core\Utility\GeneralUtility;
 class TranslationStatusController extends \TYPO3\CMS\Backend\Module\AbstractFunctionModule {
 
        /**
+        * @var IconFactory
+        */
+       protected $iconFactory;
+
+       /**
+        * Construct for initialize class variables
+        */
+       public function __construct() {
+               $this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);
+       }
+
+       /**
         * Returns the menu array
         *
         * @return array
@@ -258,7 +273,7 @@ class TranslationStatusController extends \TYPO3\CMS\Backend\Module\AbstractFunc
                                $tCells[] = '<td><a href="#" onclick="' . htmlspecialchars($onClick)
                                        . '" title="' . $lang->sL(
                                                'LLL:EXT:frontend/Resources/Private/Language/locallang_webinfo.xlf:lang_getlangsta_createNewTranslationHeaders'
-                                       ) . '">' . IconUtility::getSpriteIcon('actions-document-new') . '</a></td>';
+                                       ) . '">' . $this->iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL) . '</a></td>';
                        }
                }
 
index a5cb5f0..2a21a33 100755 (executable)
@@ -619,8 +619,10 @@ class AdminPanelView {
                        if ($GLOBALS['TSFE']->sys_language_uid) {
                                $params = '&sys_language_uid=' . $GLOBALS['TSFE']->sys_language_uid;
                        }
-                       $icon = IconUtility::getSpriteIcon('actions-document-new', array('title' => $this->extGetLL('edit_newContentElement', FALSE)));
-                       $toolBar .= '<a class="t3-icon btn btn-default" href="' . htmlspecialchars($newContentWizScriptPath . 'id=' . $id . $params . '&returnUrl=' . rawurlencode($returnUrl)) . '">' . $icon . '</a>';
+                       $icon = $iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL);
+                       $link = $newContentWizScriptPath . 'id=' . $id . $params . '&returnUrl=' . rawurlencode($returnUrl);
+                       $toolBar .= '<a class="t3-icon btn btn-default" href="' . htmlspecialchars($link) . '"' .
+                               $toolBar .= 'title="' . $this->extGetLL('edit_newContentElement', FALSE) .  '"">' . $icon . '</a>';
                }
                if ($perms & Permission::PAGE_EDIT) {
                        $icon = $iconFactory->getIcon('actions-document-move', Icon::SIZE_SMALL);
index 0732e4f..de9bb40 100644 (file)
@@ -264,7 +264,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                                $onClick = htmlspecialchars('return jumpExt(' . GeneralUtility::quoteJSvalue(BackendUtility::getModuleUrl('db_new', ['id' => $this->id])) . ');');
                                $buttons['new_record'] = '<a href="#" onclick="' . $onClick . '" title="'
                                        . $lang->getLL('newRecordGeneral', TRUE) . '">'
-                                       . IconUtility::getSpriteIcon('actions-document-new') . '</a>';
+                                       . $this->iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL) . '</a>';
                        }
                        // If edit permissions are set, see
                        // \TYPO3\CMS\Core\Authentication\BackendUserAuthentication
@@ -1301,9 +1301,10 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                                if ($table !== 'pages' && $this->calcPerms & Permission::CONTENT_EDIT || $table === 'pages' && $this->calcPerms & Permission::PAGE_NEW) {
                                        if ($this->showNewRecLink($table)) {
                                                $params = '&edit[' . $table . '][' . -($row['_MOVE_PLH'] ? $row['_MOVE_PLH_uid'] : $row['uid']) . ']=new';
+                                               $icon = ($table == 'pages' ? IconUtility::getSpriteIcon('actions-page-new') : $this->iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL));
                                                $newAction = '<a class="btn btn-default" href="#" onclick="' . htmlspecialchars(BackendUtility::editOnClick($params, '', -1))
                                                        . '" title="' . $this->getLanguageService()->getLL('new' . ($table == 'pages ' ? 'Page' : 'Record'), TRUE) . '">'
-                                                       . ($table == 'pages' ? IconUtility::getSpriteIcon('actions-page-new') : IconUtility::getSpriteIcon('actions-document-new')) . '</a>';
+                                                       . $icon . '</a>';
                                                $this->addActionToCellGroup($cells, $newAction, 'new');
                                        }
                                }
index b223965..97b43ec 100644 (file)
@@ -17,6 +17,8 @@ namespace TYPO3\CMS\Scheduler\Controller;
 use TYPO3\CMS\Backend\Utility\BackendUtility;
 use TYPO3\CMS\Backend\Utility\IconUtility;
 use TYPO3\CMS\Core\Database\DatabaseConnection;
+use TYPO3\CMS\Core\Imaging\Icon;
+use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Messaging\FlashMessage;
 use TYPO3\CMS\Core\Messaging\FlashMessageQueue;
 use TYPO3\CMS\Core\Messaging\FlashMessageService;
@@ -81,6 +83,11 @@ class SchedulerModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClas
        protected $moduleUri;
 
        /**
+        * @var IconFactory
+        */
+       protected $iconFactory;
+
+       /**
         * @return \TYPO3\CMS\Scheduler\Controller\SchedulerModuleController
         */
        public function __construct() {
@@ -93,6 +100,7 @@ class SchedulerModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClas
                $this->view = GeneralUtility::makeInstance(\TYPO3\CMS\Fluid\View\StandaloneView::class);
                $this->view->getRequest()->setControllerExtensionName('scheduler');
                $this->moduleUri = BackendUtility::getModuleUrl($this->moduleName);
+               $this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);
 
                $pageRenderer = GeneralUtility::makeInstance(PageRenderer::class);
                $pageRenderer->loadRequireJsModule('TYPO3/CMS/Backend/Modal');
@@ -1515,7 +1523,7 @@ class SchedulerModuleController extends \TYPO3\CMS\Backend\Module\BaseScriptClas
                        $buttons['reload'] = '<a href="' . htmlspecialchars($this->moduleUri) . '" title="' . $this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.xlf:labels.reload', TRUE) . '">' . IconUtility::getSpriteIcon('actions-system-refresh') . '</a>';
                        if ($this->MOD_SETTINGS['function'] === 'scheduler' && !empty($this->getRegisteredClasses())) {
                                $link = $this->moduleUri . '&CMD=add';
-                               $image = IconUtility::getSpriteIcon('actions-document-new', array('alt' => $this->getLanguageService()->getLL('action.add')));
+                               $image = $this->iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL);
                                $buttons['addtask'] = '<a href="' . htmlspecialchars($link) . '" ' . 'title="' . $this->getLanguageService()->getLL('action.add') . '">' . $image . '</a>';
                        }
                }
index 55d30ea..c980767 100644 (file)
@@ -14,6 +14,8 @@ namespace TYPO3\CMS\SysAction;
  * The TYPO3 project - inspiring people to share!
  */
 
+use TYPO3\CMS\Core\Imaging\Icon;
+use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Page\PageRenderer;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 use TYPO3\CMS\Backend\Utility\BackendUtility;
@@ -43,9 +45,15 @@ class ActionTask implements \TYPO3\CMS\Taskcenter\TaskInterface {
        protected $moduleUrl;
 
        /**
+        * @var IconFactory
+        */
+       protected $iconFactory;
+
+       /**
         * Constructor
         */
        public function __construct(\TYPO3\CMS\Taskcenter\Controller\TaskModuleController $taskObject) {
+               $this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);
                $this->moduleUrl = BackendUtility::getModuleUrl('user_task');
                $this->taskObject = $taskObject;
                $this->getLanguageService()->includeLLFile('EXT:sys_action/Resources/Private/Language/locallang.xlf');
@@ -210,7 +218,7 @@ class ActionTask implements \TYPO3\CMS\Taskcenter\TaskInterface {
                        );
                        $content .= '<p>' .
                                '<a href="' . $link . '" title="' . $this->getLanguageService()->getLL('new-sys_action') . '">' .
-                               \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIcon('actions-document-new', array('class' => 'icon', 'title' => $this->getLanguageService()->getLL('new-sys_action'))) .
+                               $this->iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL) .
                                $this->getLanguageService()->getLL('new-sys_action') .
                                '</a></p>';
                }
@@ -776,6 +784,7 @@ class ActionTask implements \TYPO3\CMS\Taskcenter\TaskInterface {
                        // Initialize the dblist object:
                        $dblist = GeneralUtility::makeInstance(\TYPO3\CMS\SysAction\ActionList::class);
                        $dblist->script = GeneralUtility::getIndpEnv('REQUEST_URI');
+                       $dblist->backPath = $GLOBALS['BACK_PATH'];
                        $dblist->calcPerms = $this->getBackendUser()->calcPerms($this->pageinfo);
                        $dblist->thumbs = $this->getBackendUser()->uc['thumbnailsByDefault'];
                        $dblist->returnUrl = $this->taskObject->returnUrl;
@@ -852,7 +861,10 @@ class ActionTask implements \TYPO3\CMS\Taskcenter\TaskInterface {
                        if ($dblist->HTMLcode) {
                                // Making field select box (when extended view for a single table is enabled):
                                if ($dblist->table) {
+                                       $tmpBackpath = $GLOBALS['BACK_PATH'];
+                                       $GLOBALS['BACK_PATH'] = '';
                                        $content .= $dblist->fieldSelectBox($dblist->table);
+                                       $GLOBALS['BACK_PATH'] = $tmpBackpath;
                                }
                        }
                } else {
index 79957a6..68e37de 100644 (file)
@@ -7532,6 +7532,8 @@ button.close {
   position: relative;
   display: inline-block;
   overflow: hidden;
+  vertical-align: middle;
+  white-space: nowrap;
 }
 .icon img {
   display: block;
@@ -7540,53 +7542,62 @@ button.close {
 }
 .icon-markup {
   position: absolute;
-  height: 100%;
-  width: 100%;
+  display: block;
   text-align: center;
+  top: 0;
+  left: 0;
+  right: 0;
+  bottom: 0;
 }
 .icon-overlay {
   position: absolute;
   bottom: 0;
   right: 0;
-  height: 50%;
-  width: 50%;
+  height: 60%;
+  width: 60%;
   text-align: center;
 }
+.icon-unify {
+  display: block;
+}
 .icon-size-small {
   height: 16px;
   width: 16px;
+  line-height: 16px;
 }
 .icon-size-small .icon-unify {
   line-height: 16px;
   font-size: 14px;
 }
 .icon-size-small .icon-overlay .icon-unify {
-  line-height: 8px;
-  font-size: 7px;
+  line-height: 10px;
+  font-size: 9px;
 }
 .icon-size-default {
   height: 32px;
   width: 32px;
+  line-height: 32px;
 }
 .icon-size-default .icon-unify {
   line-height: 32px;
   font-size: 28px;
 }
 .icon-size-default .icon-overlay .icon-unify {
-  line-height: 16px;
-  font-size: 14px;
+  line-height: 20px;
+  font-size: 18px;
 }
 .icon-size-large {
   height: 48px;
   width: 48px;
+  line-height: 48px;
 }
 .icon-size-large .icon-unify {
   line-height: 48px;
   font-size: 42px;
 }
 .icon-size-large .icon-overlay .icon-unify {
-  line-height: 24px;
-  font-size: 21px;
+  line-height: 30px;
+  font-size: 26px;
 }
 .icon-default-not-found {
   color: #c83c3c;
index 26fa497..b36ec8a 100755 (executable)
@@ -17,6 +17,8 @@ namespace TYPO3\CMS\Tstemplate\Controller;
 use TYPO3\CMS\Backend\Module\BaseScriptClass;
 use TYPO3\CMS\Backend\Template\DocumentTemplate;
 use TYPO3\CMS\Core\DataHandling\DataHandler;
+use TYPO3\CMS\Core\Imaging\Icon;
+use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Messaging\FlashMessage;
 use TYPO3\CMS\Core\TypoScript\ExtendedTemplateService;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
@@ -92,9 +94,15 @@ class TypoScriptTemplateModuleController extends BaseScriptClass {
        protected $moduleName = 'web_ts';
 
        /**
+        * @var IconFactory
+        */
+       protected $iconFactory;
+
+       /**
         * Constructor
         */
        public function __construct() {
+               $this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);
                $this->getLanguageService()->includeLLFile('EXT:tstemplate/Resources/Private/Language/locallang.xlf');
 
                $this->MCONF = array(
@@ -280,7 +288,7 @@ class TypoScriptTemplateModuleController extends BaseScriptClass {
                                        'template' => 'all',
                                        'createExtension' => 'new'
                                );
-                               $buttons['new'] = '<a href="' . htmlspecialchars(BackendUtility::getModuleUrl('web_ts', $urlParameters)) . '" title="' . $lang->sL('LLL:EXT:lang/locallang_core.xlf:db_new.php.pagetitle', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-new') . '</a>';
+                               $buttons['new'] = '<a href="' . htmlspecialchars(BackendUtility::getModuleUrl('web_ts', $urlParameters)) . '" title="' . $lang->sL('LLL:EXT:lang/locallang_core.xlf:db_new.php.pagetitle', TRUE) . '">' . $this->iconFactory->getIcon('actions-document-new', Icon::SIZE_SMALL) . '</a>';
                                if (!empty($this->e) && !GeneralUtility::_POST('saveclose')) {
                                        // no NEW-button while edit
                                        $buttons['new'] = '';