Minor - correcting indentation

skala
Julio Montoya 14 years ago
parent 770c678cd5
commit d0a0052411
  1. 12
      main/inc/lib/image.lib.php

@ -40,7 +40,6 @@ class image {
$size [1] = $this->bgy; $size [1] = $this->bgy;
if ($border == 1) { if ($border == 1) {
if ($specific_size) { if ($specific_size) {
$width = $thumbw; $width = $thumbw;
$height = $thumbh; $height = $thumbh;
@ -49,7 +48,6 @@ class image {
$width = (int)($size[0] * $scale); $width = (int)($size[0] * $scale);
$height = (int)($size[1] * $scale); $height = (int)($size[1] * $scale);
} }
$deltaw = (int)(($thumbw - $width) / 2); $deltaw = (int)(($thumbw - $width) / 2);
$deltah = (int)(($thumbh - $height) / 2); $deltah = (int)(($thumbh - $height) / 2);
$dst_img = @ImageCreateTrueColor($thumbw, $thumbh); $dst_img = @ImageCreateTrueColor($thumbw, $thumbh);
@ -58,10 +56,7 @@ class image {
} }
$this->bgx = $thumbw; $this->bgx = $thumbw;
$this->bgy = $thumbh; $this->bgy = $thumbh;
} } elseif ($border == 0) {
elseif ($border == 0) {
if ($specific_size) { if ($specific_size) {
$width = $thumbw; $width = $thumbw;
$height = $thumbh; $height = $thumbh;
@ -70,19 +65,14 @@ class image {
$width = (int)($size[0] * $scale); $width = (int)($size[0] * $scale);
$height = (int)($size[1] * $scale); $height = (int)($size[1] * $scale);
} }
$deltaw = 0; $deltaw = 0;
$deltah = 0; $deltah = 0;
$dst_img = @ImageCreateTrueColor($width, $height); $dst_img = @ImageCreateTrueColor($width, $height);
$this->bgx = $width; $this->bgx = $width;
$this->bgy = $height; $this->bgy = $height;
} }
$src_img = $this->bg; $src_img = $this->bg;
@ImageCopyResampled($dst_img, $src_img, $deltaw, $deltah, 0, 0, $width, $height, ImageSX($src_img), ImageSY($src_img)); @ImageCopyResampled($dst_img, $src_img, $deltaw, $deltah, 0, 0, $width, $height, ImageSX($src_img), ImageSY($src_img));
$this->bg=$dst_img; $this->bg=$dst_img;
@imagedestroy($src_img); @imagedestroy($src_img);
} }

Loading…
Cancel
Save