[!!!][TASK] Remove deprecated code from EXT:filelist 09/59309/2
authorWouter Wolters <typo3@wouterwolters.nl>
Sun, 30 Dec 2018 14:54:47 +0000 (15:54 +0100)
committerBenni Mack <benni@typo3.org>
Fri, 4 Jan 2019 13:33:18 +0000 (14:33 +0100)
Resolves: #87309
Releases: master
Change-Id: I0397d3cab0f5957482553640180bfebc0a36ea15
Reviewed-on: https://review.typo3.org/59309
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
Reviewed-by: Benni Mack <benni@typo3.org>
Tested-by: Benni Mack <benni@typo3.org>
typo3/sysext/core/Documentation/Changelog/master/Breaking-87193-DeprecatedFunctionalityRemoved.rst
typo3/sysext/filelist/Classes/Controller/FileListController.php
typo3/sysext/filelist/Classes/FileFacade.php
typo3/sysext/filelist/Classes/FileList.php
typo3/sysext/install/Configuration/ExtensionScanner/Php/MethodCallMatcher.php

index 636145c..e480273 100644 (file)
@@ -305,6 +305,7 @@ The following PHP class methods that have been previously deprecated for v9 have
 * :php:`TYPO3\CMS\Extbase\Mvc\Controller\Arguments->getValidationResults()`
 * :php:`TYPO3\CMS\Extbase\Service\EnvironmentService->isEnvironmentInCliMode`
 * :php:`TYPO3\CMS\Fluid\Core\Widget\Bootstrap->configureObjectManager()`
+* :php:`TYPO3\CMS\Filelist\FileFacade::getIcon()`
 * :php:`TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer->addParams()`
 * :php:`TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer->calcIntExplode()`
 * :php:`TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer->currentPageUrl()`
@@ -564,6 +565,13 @@ The following class methods have changed visibility:
 * :php:`TYPO3\CMS\Core\TypoScript\TemplateService->processIncludes()` changed from public to protected
 * :php:`TYPO3\CMS\Core\TypoScript\TemplateService->substituteConstants()` changed from public to protected
 * :php:`TYPO3\CMS\Core\TypoScript\TemplateService->versionOL()` changed from public to protected
+* :php:`TYPO3\CMS\Beuser\Controller\BackendUserController->initializeView()` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->menuConfig()` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->initializeView()` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->initializeIndexAction()` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->indexAction()` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->missingFolderAction()` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->searchAction()` changed from public to protected
 * :php:`TYPO3\CMS\Frontend\ContentObject\Menu\AbstractMenuContentObject->accessKey()` changed from public to protected
 * :php:`TYPO3\CMS\Frontend\ContentObject\Menu\AbstractMenuContentObject->changeLinksForAccessRestrictedPages()` changed from public to protected
 * :php:`TYPO3\CMS\Frontend\ContentObject\Menu\AbstractMenuContentObject->getBannedUids()` changed from public to protected
@@ -746,6 +754,15 @@ The following class properties have changed visibility:
 * :php:`TYPO3\CMS\Core\TypoScript\TemplateService->sectionsMatch` changed from public to protected
 * :php:`TYPO3\CMS\Core\TypoScript\TemplateService->simulationHiddenOrTime` changed from public to protected
 * :php:`TYPO3\CMS\Core\TypoScript\TemplateService->sitetitle` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->MOD_MENU` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->MOD_SETTINGS` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->doc` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->id` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->pointer` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->table` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->imagemode` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->cmd` changed from public to protected
+* :php:`TYPO3\CMS\Filelist\Controller\FileListController->filelist` changed from public to protected
 * :php:`TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController->cacheContentFlag` changed from public to protected
 * :php:`TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController->cacheExpires` changed from public to protected
 * :php:`TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController->cacheTimeOutDefault` changed from public to protected
index daf3321..cc45122 100644 (file)
@@ -16,12 +16,9 @@ namespace TYPO3\CMS\Filelist\Controller;
 
 use TYPO3\CMS\Backend\Clipboard\Clipboard;
 use TYPO3\CMS\Backend\Template\Components\ButtonBar;
-use TYPO3\CMS\Backend\Template\DocumentTemplate;
 use TYPO3\CMS\Backend\Utility\BackendUtility;
 use TYPO3\CMS\Backend\View\BackendTemplateView;
 use TYPO3\CMS\Core\Authentication\BackendUserAuthentication;
-use TYPO3\CMS\Core\Compatibility\PublicMethodDeprecationTrait;
-use TYPO3\CMS\Core\Compatibility\PublicPropertyDeprecationTrait;
 use TYPO3\CMS\Core\Imaging\Icon;
 use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Localization\LanguageService;
@@ -47,32 +44,6 @@ use TYPO3\CMS\Filelist\FileList;
  */
 class FileListController extends ActionController
 {
-    use PublicPropertyDeprecationTrait;
-    use PublicMethodDeprecationTrait;
-
-    private $deprecatedPublicProperties = [
-        'MOD_MENU' => 'Using FileListController::$MOD_MENU is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'MOD_SETTINGS' => 'Using FileListController::$MOD_SETTINGS is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'doc' => 'Using FileListController::$doc is deprecated, property will be removed in TYPO3 v10.0.',
-        'id' => 'Using FileListController::$id is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'pointer' => 'Using FileListController::$pointer is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'table' => 'Using FileListController::$table is deprecated, , property will be removed in TYPO3 v10.0.',
-        'imagemode' => 'Using FileListController::$imagemode is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'cmd' => 'Using FileListController::$cmd is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'filelist' => 'Using FileListController::$filelist is deprecated and will not be possible anymore in TYPO3 v10.0.',
-    ];
-
-    /**
-     * @var array
-     */
-    private $deprecatedPublicMethods = [
-        'menuConfig' => 'Using FileListController::menuConfig() is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'initializeView' => 'Using FileListController::initializeView() is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'initializeIndexAction' => 'Using FileListController::initializeIndexAction() is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'indexAction' => 'Using FileListController::indexAction() is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'missingFolderAction' => 'Using FileListController::missingFolderAction() is deprecated and will not be possible anymore in TYPO3 v10.0.',
-        'searchAction' => 'Using FileListController::searchAction() is deprecated and will not be possible anymore in TYPO3 v10.0.',
-    ];
 
     /**
      * @var array
@@ -85,14 +56,6 @@ class FileListController extends ActionController
     protected $MOD_SETTINGS = [];
 
     /**
-     * Document template object
-     *
-     * @var DocumentTemplate
-     * @deprecated since TYPO3 v9, will be removed in TYPO3 v10.0
-     */
-    protected $doc;
-
-    /**
      * "id" -> the path to list.
      *
      * @var string
@@ -117,13 +80,6 @@ class FileListController extends ActionController
     protected $pointer;
 
     /**
-     * "Table"
-     * @var string
-     * @deprecated since TYPO3 v9, will be removed in TYPO3 v10.0
-     */
-    protected $table;
-
-    /**
      * Thumbnail mode.
      *
      * @var string
@@ -190,14 +146,12 @@ class FileListController extends ActionController
      */
     public function initializeObject()
     {
-        $this->doc = GeneralUtility::makeInstance(DocumentTemplate::class);
         $this->getLanguageService()->includeLLFile('EXT:filelist/Resources/Private/Language/locallang_mod_file_list.xlf');
         $this->getLanguageService()->includeLLFile('EXT:core/Resources/Private/Language/locallang_misc.xlf');
 
         // Setting GPvars:
         $this->id = ($combinedIdentifier = GeneralUtility::_GP('id'));
         $this->pointer = GeneralUtility::_GP('pointer');
-        $this->table = GeneralUtility::_GP('table');
         $this->imagemode = GeneralUtility::_GP('imagemode');
         $this->cmd = GeneralUtility::_GP('cmd');
         $this->overwriteExistingFiles = DuplicationBehavior::cast(GeneralUtility::_GP('overwriteExistingFiles'));
@@ -378,8 +332,7 @@ class FileListController extends ActionController
         // There there was access to this file path, continue, make the list
         if ($this->folderObject) {
             $userTsConfig = $this->getBackendUser()->getTSConfig();
-            // @deprecated since TYPO3 v9, will be removed in TYPO3 v10.0. Argument $this will be removed in TYPO3 v10.0.
-            $this->filelist = GeneralUtility::makeInstance(FileList::class, $this);
+            $this->filelist = GeneralUtility::makeInstance(FileList::class);
             $this->filelist->thumbs = $GLOBALS['TYPO3_CONF_VARS']['GFX']['thumbnails'] && $this->MOD_SETTINGS['displayThumbs'];
             // Create clipboard object and initialize that
             $this->filelist->clipObj = GeneralUtility::makeInstance(Clipboard::class);
index 14dc293..379391e 100644 (file)
@@ -18,7 +18,6 @@ use TYPO3\CMS\Backend\Clipboard\Clipboard;
 use TYPO3\CMS\Backend\Utility\BackendUtility;
 use TYPO3\CMS\Core\Authentication\BackendUserAuthentication;
 use TYPO3\CMS\Core\Database\ConnectionPool;
-use TYPO3\CMS\Core\Imaging\Icon;
 use TYPO3\CMS\Core\Imaging\IconFactory;
 use TYPO3\CMS\Core\Localization\LanguageService;
 use TYPO3\CMS\Core\Resource\FileInterface;
@@ -63,17 +62,6 @@ class FileFacade
     }
 
     /**
-     * @return string
-     * @deprecated since TYPO3 v9, will be removed in TYPO3 v10.0.
-     */
-    public function getIcon(): string
-    {
-        trigger_error('FileFacade->getIcon() will be removed in TYPO3 v10.0, use ViewHelper <core:iconForResource /> instead.', E_USER_DEPRECATED);
-        $title = htmlspecialchars($this->resource->getName() . ' [' . (int)$this->resource->getProperty('uid') . ']');
-        return '<span title="' . $title . '">' . $this->iconFactory->getIconForResource($this->resource, Icon::SIZE_SMALL) . '</span>';
-    }
-
-    /**
      * @return \TYPO3\CMS\Core\Resource\FileInterface
      */
     public function getResource(): FileInterface
index 5ab126a..affebd3 100644 (file)
@@ -37,7 +37,6 @@ use TYPO3\CMS\Core\Type\Bitmask\JsConfirmation;
 use TYPO3\CMS\Core\Utility\GeneralUtility;
 use TYPO3\CMS\Core\Utility\MathUtility;
 use TYPO3\CMS\Filelist\Configuration\ThumbnailConfiguration;
-use TYPO3\CMS\Filelist\Controller\FileListController;
 
 /**
  * Class for rendering of File>Filelist
@@ -264,22 +263,14 @@ class FileList
     protected $id = 0;
 
     /**
-     * @var FileListController
-     * @deprecated since TYPO3 v9, will be removed in TYPO3 v10.0.
-     */
-    protected $fileListController;
-
-    /**
      * @var ThumbnailConfiguration
      */
     protected $thumbnailConfiguration;
 
     /**
      * Construct
-     *
-     * @param FileListController $fileListController @deprecated since TYPO3 v9, will be removed in TYPO3 v10.0
      */
-    public function __construct(FileListController $fileListController = null)
+    public function __construct()
     {
         $backendUser = $this->getBackendUser();
         if (isset($backendUser->uc['titleLen']) && $backendUser->uc['titleLen'] > 0) {
@@ -288,7 +279,6 @@ class FileList
         $this->iconFactory = GeneralUtility::makeInstance(IconFactory::class);
         $this->getTranslateTools();
         $this->determineScriptUrl();
-        $this->fileListController = $fileListController;
         $this->thumbnailConfiguration = GeneralUtility::makeInstance(ThumbnailConfiguration::class);
         $this->iLimit = MathUtility::forceIntegerInRange(
             $backendUser->getTSConfig()['options.']['file_list.']['filesPerPage'] ?? $this->iLimit,
index 9542af5..33c35d2 100644 (file)
@@ -1868,6 +1868,7 @@ return [
         'maximumNumberOfArguments' => 0,
         'restFiles' => [
             'Deprecation-83942-DeprecatedFileFacadegetIcon.rst',
+            'Breaking-87193-DeprecatedFunctionalityRemoved.rst'
         ],
     ],
     'TYPO3\CMS\Core\Core\Bootstrap->redirectToInstallTool' => [