Commit 0d326f07 authored by Frank Nägler's avatar Frank Nägler Committed by Anja Leichsenring
Browse files

[TASK] Replace icon by the IconFactory actions-view-go-up

Resolves: #69596
Releases: master
Change-Id: I26ac73af5e2d863753c229b4aef3bfdc3c852456
Reviewed-on: http://review.typo3.org/43110

Reviewed-by: Georg Ringer's avatarGeorg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer's avatarGeorg Ringer <georg.ringer@gmail.com>
Reviewed-by: Anja Leichsenring's avatarAnja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring's avatarAnja Leichsenring <aleichsenring@ab-softlab.de>
parent d60237c5
......@@ -19,6 +19,8 @@ use Psr\Http\Message\ResponseInterface;
use TYPO3\CMS\Core\Http\Response;
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;
/**
......@@ -82,6 +84,11 @@ class MoveElementController implements \TYPO3\CMS\Core\Http\ControllerInterface
*/
public $content;
/**
* @var IconFactory
*/
protected $iconFactory;
/**
* Constructor
*/
......@@ -114,6 +121,7 @@ class MoveElementController implements \TYPO3\CMS\Core\Http\ControllerInterface
// Starting document content (header):
$this->content = '';
$this->content .= $this->doc->header($this->getLanguageService()->getLL('movingElement'));
$this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);
}
/**
......@@ -169,7 +177,7 @@ class MoveElementController implements \TYPO3\CMS\Core\Http\ControllerInterface
$pidPageInfo = BackendUtility::readPageAccess($pageInfo['pid'], $this->perms_clause);
if (is_array($pidPageInfo)) {
if ($backendUser->isInWebMount($pidPageInfo['pid'], $this->perms_clause)) {
$code .= '<a href="' . htmlspecialchars(GeneralUtility::linkThisScript(array('uid' => (int)$pageInfo['pid'], 'moveUid' => $this->moveUid))) . '">' . IconUtility::getSpriteIcon('actions-view-go-up') . BackendUtility::getRecordTitle('pages', $pidPageInfo, TRUE) . '</a><br />';
$code .= '<a href="' . htmlspecialchars(GeneralUtility::linkThisScript(array('uid' => (int)$pageInfo['pid'], 'moveUid' => $this->moveUid))) . '">' . $this->iconFactory->getIcon('actions-view-go-up', Icon::SIZE_SMALL) . BackendUtility::getRecordTitle('pages', $pidPageInfo, TRUE) . '</a><br />';
} else {
$code .= IconUtility::getSpriteIconForRecord('pages', $pidPageInfo) . BackendUtility::getRecordTitle('pages', $pidPageInfo, TRUE) . '<br />';
}
......@@ -219,7 +227,7 @@ class MoveElementController implements \TYPO3\CMS\Core\Http\ControllerInterface
$code .= '<a href="' . htmlspecialchars(GeneralUtility::linkThisScript(array(
'uid' => (int)$pageInfo['pid'],
'moveUid' => $this->moveUid
))) . '">' . IconUtility::getSpriteIcon('actions-view-go-up') . BackendUtility::getRecordTitle('pages', $pidPageInfo, TRUE) . '</a><br />';
))) . '">' . $this->iconFactory->getIcon('actions-view-go-up', Icon::SIZE_SMALL) . BackendUtility::getRecordTitle('pages', $pidPageInfo, TRUE) . '</a><br />';
} else {
$code .= IconUtility::getSpriteIconForRecord('pages', $pidPageInfo) . BackendUtility::getRecordTitle('pages', $pidPageInfo, TRUE) . '<br />';
}
......
......@@ -470,10 +470,9 @@ class FileList extends AbstractRecordList {
$parentFolder = $currentFolder->getParentFolder();
if ($parentFolder->getIdentifier() !== $currentFolder->getIdentifier() && $currentStorage->isWithinFileMountBoundaries($parentFolder)) {
$levelUp = $this->linkWrapDir(
IconUtility::getSpriteIcon(
'actions-view-go-up',
array('title' => $this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.php:labels.upOneLevel', TRUE))
),
'<span title="' . $this->getLanguageService()->sL('LLL:EXT:lang/locallang_core.php:labels.upOneLevel', TRUE) . '">'
. $this->iconFactory->getIcon('actions-view-go-up', Icon::SIZE_SMALL)
. '</span>',
$parentFolder
);
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment