Skip to content

Commit 7256b58

Browse files
author
Martin Brecht-Precht
committed
Some code cleanup.
1 parent 4702f72 commit 7256b58

File tree

2 files changed

+14
-14
lines changed

2 files changed

+14
-14
lines changed

QrRender/PathFinder/PathPoint.php

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -13,39 +13,39 @@ class PathPoint
1313
/**
1414
* @var int
1515
*/
16-
private $x;
16+
private $xPosition;
1717

1818
/**
1919
* @var int
2020
*/
21-
private $y;
21+
private $yPosition;
2222

2323
/**
2424
* PathPoint constructor.
2525
*
26-
* @param int $x
27-
* @param int $y
26+
* @param int $xPosition
27+
* @param int $yPosition
2828
*/
29-
public function __construct($x, $y)
29+
public function __construct($xPosition, $yPosition)
3030
{
31-
$this->x = $x;
32-
$this->y = $y;
31+
$this->xPosition = $xPosition;
32+
$this->yPosition = $yPosition;
3333
}
3434

3535
/**
3636
* @return int
3737
*/
38-
public function getX()
38+
public function getXPosition()
3939
{
40-
return $this->x;
40+
return $this->xPosition;
4141
}
4242

4343
/**
4444
* @return int
4545
*/
46-
public function getY()
46+
public function getYPosition()
4747
{
48-
return $this->y;
48+
return $this->yPosition;
4949
}
5050

5151
}

QrRender/QrCodeRendererEps.php

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -82,9 +82,9 @@ public function render(QrCode $qrCode, $filename)
8282
*/
8383
private function convertPoint(PathPoint $point)
8484
{
85-
$x = self::POINTS_PER_BLOCK * ($point->getX() + self::MARGIN);
86-
$y = $this->epsHeight - self::POINTS_PER_BLOCK * ($point->getY() + self::MARGIN);
87-
return $x . ' ' . $y . ' ';
85+
$xPosition = self::POINTS_PER_BLOCK * ($point->getXPosition() + self::MARGIN);
86+
$yPosition = $this->epsHeight - self::POINTS_PER_BLOCK * ($point->getYPosition() + self::MARGIN);
87+
return $xPosition . ' ' . $yPosition . ' ';
8888
}
8989

9090
}

0 commit comments

Comments
 (0)