[BUGFIX] Various static calls to non-static functions 79/27679/2
authorMarkus Klein <klein.t3@mfc-linz.at>
Tue, 18 Feb 2014 09:14:53 +0000 (10:14 +0100)
committerMarkus Klein <klein.t3@mfc-linz.at>
Tue, 18 Feb 2014 23:04:40 +0000 (00:04 +0100)
Resolves: #56067
Releases: 6.2, 6.1, 6.0
Change-Id: I6d1e19026afde81bec46cec3dff9060fa6042c43
Reviewed-on: https://review.typo3.org/27679
Reviewed-by: Oliver Klee
Reviewed-by: Wouter Wolters
Reviewed-by: Markus Klein
Tested-by: Markus Klein
typo3/sysext/frontend/Classes/ContentObject/ContentObjectRenderer.php
typo3/sysext/frontend/Classes/ContentObject/Menu/AbstractMenuContentObject.php
typo3/sysext/frontend/Classes/ContentObject/Menu/GraphicalMenuContentObject.php
typo3/sysext/frontend/Classes/ContentObject/Menu/TextMenuContentObject.php
typo3/sysext/indexed_search/Classes/Domain/Repository/IndexSearchRepository.php

index ee6249f..36be4ab 100644 (file)
@@ -7376,7 +7376,7 @@ class ContentObjectRenderer {
                                                                $theList = array_merge(
                                                                        GeneralUtility::intExplode(
                                                                                ',',
-                                                                               self::getTreeList($next_id, $depth - 1, $begin - 1, $dontCheckEnableFields,
+                                                                               $this->getTreeList($next_id, $depth - 1, $begin - 1, $dontCheckEnableFields,
                                                                                        $addSelectFields, $moreWhereClauses, $prevId_array, $recursionLevel + 1)
                                                                        ),
                                                                        $theList
@@ -7586,7 +7586,7 @@ class ContentObjectRenderer {
                $queryParts = $this->getWhere($table, $conf, TRUE);
                // Fields:
                if ($conf['selectFields']) {
-                       $queryParts['SELECT'] = self::sanitizeSelectPart($conf['selectFields'], $table);
+                       $queryParts['SELECT'] = $this->sanitizeSelectPart($conf['selectFields'], $table);
                } else {
                        $queryParts['SELECT'] = '*';
                }
index 347236c..403944a 100644 (file)
@@ -549,7 +549,7 @@ class AbstractMenuContentObject {
                                                $id_list_arr = array();
                                                foreach ($items as $id) {
                                                        $bA = MathUtility::forceIntegerInRange($this->conf['special.']['beginAtLevel'], 0, 100);
-                                                       $id_list_arr[] = \TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::getTreeList(-1 * $id, $depth - 1 + $bA, $bA - 1);
+                                                       $id_list_arr[] = $this->parent_cObj->getTreeList(-1 * $id, $depth - 1 + $bA, $bA - 1);
                                                }
                                                $id_list = implode(',', $id_list_arr);
                                                // Get sortField (mode)
@@ -605,7 +605,7 @@ class AbstractMenuContentObject {
                                                        $value_rec = $this->sys_page->getPage($value);
                                                        $kfieldSrc = $this->conf['special.']['keywordsField.']['sourceField'] ? $this->conf['special.']['keywordsField.']['sourceField'] : 'keywords';
                                                        // keywords.
-                                                       $kw = trim(\TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::keywords($value_rec[$kfieldSrc]));
+                                                       $kw = trim($this->parent_cObj->keywords($value_rec[$kfieldSrc]));
                                                }
                                                // *'auto', 'manual', 'tstamp'
                                                $mode = $this->conf['special.']['mode'];
@@ -650,7 +650,7 @@ class AbstractMenuContentObject {
                                                // If there are keywords and the startuid is present.
                                                if ($kw && $startUid) {
                                                        $bA = MathUtility::forceIntegerInRange($this->conf['special.']['beginAtLevel'], 0, 100);
-                                                       $id_list = \TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::getTreeList(-1 * $startUid, $depth - 1 + $bA, $bA - 1);
+                                                       $id_list = $this->parent_cObj->getTreeList(-1 * $startUid, $depth - 1 + $bA, $bA - 1);
                                                        $kwArr = explode(',', $kw);
                                                        foreach ($kwArr as $word) {
                                                                $word = trim($word);
index 366c0b0..5dcfa51 100644 (file)
@@ -442,7 +442,7 @@ class GraphicalMenuContentObject extends \TYPO3\CMS\Frontend\ContentObject\Menu\
                                                $this->I['A1'] = '';
                                                $this->I['A2'] = '';
                                        }
-                                       $this->I['IMG'] = '<img src="' . $GLOBALS['TSFE']->absRefPrefix . $this->I['val']['output_file'] . '" width="' . $this->I['val']['output_w'] . '" height="' . $this->I['val']['output_h'] . '" ' . \TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::getBorderAttr('border="0"') . ($this->mconf['disableAltText'] ? '' : ' alt="' . htmlspecialchars($this->I['altText']) . '"') . $this->I['name'] . ($this->I['val']['imgParams'] ? ' ' . $this->I['val']['imgParams'] : '') . ' />';
+                                       $this->I['IMG'] = '<img src="' . $GLOBALS['TSFE']->absRefPrefix . $this->I['val']['output_file'] . '" width="' . $this->I['val']['output_w'] . '" height="' . $this->I['val']['output_h'] . '" ' . $this->parent_cObj->getBorderAttr('border="0"') . ($this->mconf['disableAltText'] ? '' : ' alt="' . htmlspecialchars($this->I['altText']) . '"') . $this->I['name'] . ($this->I['val']['imgParams'] ? ' ' . $this->I['val']['imgParams'] : '') . ' />';
                                        // Make before, middle and after parts
                                        $this->I['parts'] = array();
                                        $this->I['parts']['ATag_begin'] = $this->I['A1'];
index 417a69a..d535959 100644 (file)
@@ -190,7 +190,7 @@ class TextMenuContentObject extends \TYPO3\CMS\Frontend\ContentObject\Menu\Abstr
                        $theName = $this->imgNamePrefix . $this->I['uid'] . $this->I['INPfix'] . $pref;
                        $name = ' ' . $this->nameAttribute . '="' . $theName . '"';
                        $GLOBALS['TSFE']->imagesOnPage[] = $imgInfo[3];
-                       $res = '<img' . ' src="' . $GLOBALS['TSFE']->absRefPrefix . $imgInfo[3] . '"' . ' width="' . $imgInfo[0] . '"' . ' height="' . $imgInfo[1] . '"' . $name . ($this->I['val'][$pref . 'ImgTagParams'] ? ' ' . $this->I['val'][($pref . 'ImgTagParams')] : '') . \TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::getBorderAttr(' border="0"');
+                       $res = '<img' . ' src="' . $GLOBALS['TSFE']->absRefPrefix . $imgInfo[3] . '"' . ' width="' . $imgInfo[0] . '"' . ' height="' . $imgInfo[1] . '"' . $name . ($this->I['val'][$pref . 'ImgTagParams'] ? ' ' . $this->I['val'][($pref . 'ImgTagParams')] : '') . $this->parent_cObj->getBorderAttr(' border="0"');
                        if (!strstr($res, 'alt="')) {
                                // Adding alt attribute if not set.
                                $res .= ' alt=""';
index d04da4d..4623608 100644 (file)
@@ -581,7 +581,7 @@ class IndexSearchRepository {
                        $siteIdNumbers = \TYPO3\CMS\Core\Utility\GeneralUtility::intExplode(',', $this->searchRootPageIdList);
                        $pageIdList = array();
                        foreach ($siteIdNumbers as $rootId) {
-                               $pageIdList[] = \TYPO3\CMS\Frontend\ContentObject\ContentObjectRenderer::getTreeList(-1 * $rootId, 9999);
+                               $pageIdList[] = $GLOBALS['TSFE']->cObj->getTreeList(-1 * $rootId, 9999);
                        }
                        $page_where = ' AND ISEC.page_id IN (' . implode(',', $pageIdList) . ')';
                }