Commit 68b9560e authored by Benni Mack's avatar Benni Mack Committed by Oliver Bartsch
Browse files

[!!!][TASK] Remove hideIfNotTranslated and hideIfDefaultLanguage methods

Resolves: #96173
Related: #92551
Releases: main
Change-Id: I675c0c677b941aed51c182595a30f7de086db7cb
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/72435


Tested-by: Wouter Wolters's avatarWouter Wolters <typo3@wouterwolters.nl>
Tested-by: core-ci's avatarcore-ci <typo3@b13.com>
Tested-by: Oliver Bartsch's avatarOliver Bartsch <bo@cedev.de>
Reviewed-by: Wouter Wolters's avatarWouter Wolters <typo3@wouterwolters.nl>
Reviewed-by: Oliver Bartsch's avatarOliver Bartsch <bo@cedev.de>
parent d49dba06
......@@ -2948,33 +2948,6 @@ class GeneralUtility
return $tempFileName;
}
/**
* Responds on input localization setting value whether the page it comes from should be hidden if no translation exists or not.
*
* @param int $l18n_cfg_fieldValue Value from "l18n_cfg" field of a page record
* @return bool TRUE if the page should be hidden
* @deprecated since TYPO3 v11, will be removed in TYPO3 v12. Use PageTranslationVisibility BitSet instead.
*/
public static function hideIfNotTranslated($l18n_cfg_fieldValue)
{
trigger_error('GeneralUtility::hideIfNotTranslated() will be removed in TYPO3 v12, use the PageTranslationVisibility BitSet API instead.', E_USER_DEPRECATED);
return $GLOBALS['TYPO3_CONF_VARS']['FE']['hidePagesIfNotTranslatedByDefault'] xor ($l18n_cfg_fieldValue & 2);
}
/**
* Returns true if the "l18n_cfg" field value is not set to hide
* pages in the default language
*
* @param int $localizationConfiguration
* @return bool
* @deprecated since TYPO3 v11, will be removed in TYPO3 v12. Use PageTranslationVisibility BitSet instead.
*/
public static function hideIfDefaultLanguage($localizationConfiguration)
{
trigger_error('GeneralUtility::hideIfDefaultLanguage() will be removed in TYPO3 v12, use the PageTranslationVisibility BitSet API instead.', E_USER_DEPRECATED);
return (bool)($localizationConfiguration & 1);
}
/**
* Calls a user-defined function/method in class
* Such a function/method should look like this: "function proc(&$params, &$ref) {...}"
......
......@@ -72,6 +72,8 @@ The following PHP static class methods that have previously been marked as depre
- :php:`\TYPO3\CMS\Core\Resource\Rendering\RendererRegistry::getInstance()`
- :php:`\TYPO3\CMS\Core\Resource\TextExtraction\TextExtractorRegistry::getInstance()`
- :php:`\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::makeCategorizable()`
- :php:`\TYPO3\CMS\Core\Utility\GeneralUtility::hideIfNotTranslated()`
- :php:`\TYPO3\CMS\Core\Utility\GeneralUtility::hideIfDefaultLanguage()`
- :php:`\TYPO3\CMS\Core\Utility\GeneralUtility::isFirstPartOfStr()`
- :php:`\TYPO3\CMS\Core\Utility\GeneralUtility::rmFromList()`
- :php:`\TYPO3\CMS\Core\Utility\GeneralUtility::stdAuthCode()`
......
......@@ -1043,6 +1043,7 @@ return [
'maximumNumberOfArguments' => 1,
'restFiles' => [
'Deprecation-92551-GeneralUtilityMethodsRelatedToPagesl18n_cfgBehavior.rst',
'Breaking-96107-DeprecatedFunctionalityRemoved.rst',
],
],
'TYPO3\CMS\Core\Utility\GeneralUtility::hideIfNotTranslated' => [
......@@ -1050,6 +1051,7 @@ return [
'maximumNumberOfArguments' => 1,
'restFiles' => [
'Deprecation-92551-GeneralUtilityMethodsRelatedToPagesl18n_cfgBehavior.rst',
'Breaking-96107-DeprecatedFunctionalityRemoved.rst',
],
],
'TYPO3\CMS\Backend\Utility\BackendUtility::fixVersioningPid' => [
......
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