Project

General

Profile

Feature #20497 » 11177_noscale.patch

Administrator Admin, 2010-05-06 01:35

View differences:

t3lib/class.t3lib_stdgraphic.php (Arbeitskopie)
$h=$data['origH'];
// if no convertion should be performed
$wh_noscale = (!$w && !$h) || ($data[0]==$info[0] && $data[1]==$info[1]); // this flag is true if the width / height does NOT dictate the image to be scaled!! (that is if no w/h is given or if the destination w/h matches the original image-dimensions....
// this flag is true if the width / height does NOT dictate
// the image to be scaled!! (that is if no w/h is
// given or if the destination w/h matches the original image-dimensions....
$noScale = (!$w && !$h) || ($data[0]==$info[0] && $data[1]==$info[1]) || $options['noScale'];
if ($wh_noscale && !$data['crs'] && !$params && !$frame && $newExt==$info[2] && !$mustCreate) {
if ($noScale && !$data['crs'] && !$params && !$frame && $newExt==$info[2] && !$mustCreate) {
// set the new width and height before returning,
// if the noScale option is set
if ($options['noScale']) {
$info[0] = $data[0];
$info[1] = $data[1];
}
$info[3] = $imagefile;
return $info;
}
typo3/sysext/cms/tslib/class.tslib_content.php (Arbeitskopie)
$fileArray['maxH']= intval($this->stdWrap($fileArray['maxH'],$fileArray['maxH.']));
$fileArray['minW']= intval($this->stdWrap($fileArray['minW'],$fileArray['minW.']));
$fileArray['minH']= intval($this->stdWrap($fileArray['minH'],$fileArray['minH.']));
$fileArray['noScale'] = $this->stdWrap($fileArray['noScale'], $fileArray['noScale.']);
$maskArray= $fileArray['m.'];
$maskImages=array();
if (is_array($fileArray['m.'])) { // Must render mask images and include in hash-calculating - else we cannot be sure the filename is unique for the setup!
(6-6/7)