[TASK] Replace sprite icon "actions-document-paste-after" with the new IconFactory 13/42413/3
authorMarkus Guenther <mail@markus-guenther.de>
Sat, 8 Aug 2015 15:30:00 +0000 (17:30 +0200)
committerWouter Wolters <typo3@wouterwolters.nl>
Sun, 9 Aug 2015 20:24:59 +0000 (22:24 +0200)
Replaces all IconUtility::getSpriteIcon calls for the icon
actions-document-paste-after with the new IconFactory.

Change-Id: Ieaa16fb8f392bbba396a5a1b8c1921d8be7ddd7b
Resolves: #68862
Releases: master
Reviewed-on: http://review.typo3.org/42413
Reviewed-by: Daniel Maier <dani-maier@gmx.de>
Tested-by: Daniel Maier <dani-maier@gmx.de>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
typo3/sysext/core/Classes/Imaging/IconRegistry.php
typo3/sysext/filelist/Classes/FileList.php
typo3/sysext/recordlist/Classes/RecordList/DatabaseRecordList.php

index 18f1976..f120a1e 100644 (file)
@@ -93,6 +93,12 @@ class IconRegistry implements \TYPO3\CMS\Core\SingletonInterface {
                                'name' => 'pencil',
                        )
                ),
+               'actions-document-paste-after' => array(
+                       'provider' => FontawesomeIconProvider::class,
+                       'options' => array(
+                               'name' => 'clipboard',
+                       )
+               ),
                'actions-document-view' => array(
                        'provider' => FontawesomeIconProvider::class,
                        'options' => array(
index 796f098..a657a77 100644 (file)
@@ -278,7 +278,7 @@ class FileList extends AbstractRecordList {
                                                $elToConfirm[$key] = $fileInfo['name'];
                                        }
                                        if ($addPasteButton) {
-                                               $buttons['PASTE'] = '<a href="' . htmlspecialchars($this->clipObj->pasteUrl('_FILE', $folderObject->getCombinedIdentifier())) . '" onclick="return ' . htmlspecialchars($this->clipObj->confirmMsg('_FILE', $this->path, 'into', $elToConfirm)) . '" title="' . $this->getLanguageService()->getLL('clip_paste', TRUE) . '">' . IconUtility::getSpriteIcon('actions-document-paste-after') . '</a>';
+                                               $buttons['PASTE'] = '<a href="' . htmlspecialchars($this->clipObj->pasteUrl('_FILE', $folderObject->getCombinedIdentifier())) . '" onclick="return ' . htmlspecialchars($this->clipObj->confirmMsg('_FILE', $this->path, 'into', $elToConfirm)) . '" title="' . $this->getLanguageService()->getLL('clip_paste', TRUE) . '">' . $this->iconFactory->getIcon('actions-document-paste-after', Icon::SIZE_SMALL) . '</a>';
                                        }
                                }
                        }
@@ -418,7 +418,7 @@ class FileList extends AbstractRecordList {
                                                        $elToConfirm[$key] = $fileInfo['name'];
                                                }
                                                if ($addPasteButton) {
-                                                       $cells[] = '<a class="btn btn-default" href="' . htmlspecialchars($this->clipObj->pasteUrl('_FILE', $this->folderObject->getCombinedIdentifier())) . '" onclick="return ' . htmlspecialchars($this->clipObj->confirmMsg('_FILE', $this->path, 'into', $elToConfirm)) . '" title="' . $this->getLanguageService()->getLL('clip_paste', 1) . '">' . IconUtility::getSpriteIcon('actions-document-paste-after') . '</a>';
+                                                       $cells[] = '<a class="btn btn-default" href="' . htmlspecialchars($this->clipObj->pasteUrl('_FILE', $this->folderObject->getCombinedIdentifier())) . '" onclick="return ' . htmlspecialchars($this->clipObj->confirmMsg('_FILE', $this->path, 'into', $elToConfirm)) . '" title="' . $this->getLanguageService()->getLL('clip_paste', 1) . '">' . $this->iconFactory->getIcon('actions-document-paste-after', Icon::SIZE_SMALL) . '</a>';
                                                }
                                        }
                                        if ($this->clipObj->current !== 'normal' && $iOut) {
index eb10d44..6b59dbe 100644 (file)
@@ -283,7 +283,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                                        $onClick = htmlspecialchars(('return ' . $this->clipObj->confirmMsg('pages', $this->pageRow, 'into', $elFromTable)));
                                        $buttons['paste'] = '<a href="' . htmlspecialchars($this->clipObj->pasteUrl('', $this->id))
                                                . '" onclick="' . $onClick . '" title="' . $lang->getLL('clip_paste', TRUE) . '">'
-                                               . IconUtility::getSpriteIcon('actions-document-paste-after') . '</a>';
+                                               . $this->iconFactory->getIcon('actions-document-paste-after', Icon::SIZE_SMALL) . '</a>';
                                }
                        }
                        // Cache
@@ -916,7 +916,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                                                $onClick = htmlspecialchars('return ' . $this->clipObj->confirmMsg('pages', $this->pageRow, 'into', $elFromTable));
                                                $cells['pasteAfter'] = '<a class="btn btn-default" href="' . $href . '" onclick="' . $onClick
                                                        . '" title="' . $lang->getLL('clip_paste', TRUE) . '">'
-                                                       . IconUtility::getSpriteIcon('actions-document-paste-after') . '</a>';
+                                                       . $this->iconFactory->getIcon('actions-document-paste-after', Icon::SIZE_SMALL) . '</a>';
                                        }
                                        // If the numeric clipboard pads are enabled, display the control icons for that:
                                        if ($this->clipObj->current != 'normal') {
@@ -1560,7 +1560,7 @@ class DatabaseRecordList extends AbstractDatabaseRecordList {
                                : '<a class="btn btn-default" href="' . htmlspecialchars($this->clipObj->pasteUrl($table, -$row['uid'])) . '" onclick="'
                                        . htmlspecialchars(('return ' . $this->clipObj->confirmMsg($table, $row, 'after', $elFromTable)))
                                        . '" title="' . $this->getLanguageService()->getLL('clip_pasteAfter', TRUE) . '">'
-                                       . IconUtility::getSpriteIcon('actions-document-paste-after') . '</a>';
+                                       . $this->iconFactory->getIcon('actions-document-paste-after', Icon::SIZE_SMALL) . '</a>';
                }
                // Now, looking for elements in general:
                $elFromTable = $this->clipObj->elFromTable('');