summaryrefslogtreecommitdiff
path: root/app/Report/ReportParserGenerate.php
diff options
context:
space:
mode:
authorGreg Roach <fisharebest@gmail.com>2017-07-13 14:48:04 +0100
committerGreg Roach <fisharebest@gmail.com>2017-07-13 14:48:04 +0100
commit3c3b90dec7b6af8ce516d659bda403ea7b512725 (patch)
tree4c8438e46434d283e270d08214b9057f84dbe560 /app/Report/ReportParserGenerate.php
parent2694a834d68048dab34572e6f54c7164e58d56e6 (diff)
downloadwebtrees-3c3b90dec7b6af8ce516d659bda403ea7b512725.tar.gz
webtrees-3c3b90dec7b6af8ce516d659bda403ea7b512725.tar.bz2
webtrees-3c3b90dec7b6af8ce516d659bda403ea7b512725.zip
Unused code
Diffstat (limited to 'app/Report/ReportParserGenerate.php')
-rw-r--r--app/Report/ReportParserGenerate.php24
1 files changed, 12 insertions, 12 deletions
diff --git a/app/Report/ReportParserGenerate.php b/app/Report/ReportParserGenerate.php
index 4380dd53f1..275fceea84 100644
--- a/app/Report/ReportParserGenerate.php
+++ b/app/Report/ReportParserGenerate.php
@@ -1640,14 +1640,14 @@ class ReportParserGenerate extends ReportParserBase {
) && $mediaobject->canShow() && $mediaobject->fileExists('main')
) {
if ($width > 0 && $height == 0) {
- $perc = $width / $attributes['adjW'];
- $height = round($attributes['adjH'] * $perc);
+ $perc = $width / $attributes[0];
+ $height = round($attributes[1] * $perc);
} elseif ($height > 0 && $width == 0) {
- $perc = $height / $attributes['adjH'];
- $width = round($attributes['adjW'] * $perc);
+ $perc = $height / $attributes[1];
+ $width = round($attributes[0] * $perc);
} else {
- $width = $attributes['adjW'];
- $height = $attributes['adjH'];
+ $width = $attributes[0];
+ $height = $attributes[1];
}
$image = $this->report_root->createImageFromObject($mediaobject, $left, $top, $width, $height, $align, $ln);
$this->wt_report->addElement($image);
@@ -1741,14 +1741,14 @@ class ReportParserGenerate extends ReportParserBase {
) && $mediaobject->canShow() && $mediaobject->fileExists('main')
) {
if ($width > 0 && $height == 0) {
- $perc = $width / $attributes['adjW'];
- $height = round($attributes['adjH'] * $perc);
+ $perc = $width / $attributes[0];
+ $height = round($attributes[1] * $perc);
} elseif ($height > 0 && $width == 0) {
- $perc = $height / $attributes['adjH'];
- $width = round($attributes['adjW'] * $perc);
+ $perc = $height / $attributes[1];
+ $width = round($attributes[0] * $perc);
} else {
- $width = $attributes['adjW'];
- $height = $attributes['adjH'];
+ $width = $attributes[0];
+ $height = $attributes[1];
}
$image = $this->report_root->createImageFromObject($mediaobject, $left, $top, $width, $height, $align, $ln);
$this->wt_report->addElement($image);