Skip to content

Commit 60cfde7

Browse files
committed
Code cleanup
1 parent a8585da commit 60cfde7

File tree

11 files changed

+14
-27
lines changed

11 files changed

+14
-27
lines changed

src/PhpPresentation/HashTable.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@
1717

1818
namespace PhpOffice\PhpPresentation;
1919

20-
use PhpOffice\PhpPresentation\ComparableInterface;
21-
2220
/**
2321
* \PhpOffice\PhpPresentation\HashTable
2422
*/

src/PhpPresentation/Reader/ODPresentation.php

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,7 @@
2424
use PhpOffice\PhpPresentation\Shape\Drawing\Gd;
2525
use PhpOffice\PhpPresentation\Shape\RichText;
2626
use PhpOffice\PhpPresentation\Shape\RichText\Paragraph;
27+
use PhpOffice\PhpPresentation\Slide\Background\Image;
2728
use PhpOffice\PhpPresentation\Style\Bullet;
2829
use PhpOffice\PhpPresentation\Style\Color;
2930
use PhpOffice\PhpPresentation\Style\Font;
@@ -214,7 +215,7 @@ protected function loadStyle(\DOMElement $nodeStyle)
214215
$contentImg = $this->oZip->getFromName($this->arrayCommonStyles[$nameStyle]['path']);
215216
file_put_contents($tmpBkgImg, $contentImg);
216217

217-
$oBackground = new \PhpOffice\PhpPresentation\Slide\Background\Image();
218+
$oBackground = new Image();
218219
$oBackground->setPath($tmpBkgImg);
219220
}
220221
}

src/PhpPresentation/Shape/Chart.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
namespace PhpOffice\PhpPresentation\Shape;
1919

20-
use PhpOffice\PhpPresentation\AbstractShape;
2120
use PhpOffice\PhpPresentation\ComparableInterface;
2221
use PhpOffice\PhpPresentation\Shape\Chart\Legend;
2322
use PhpOffice\PhpPresentation\Shape\Chart\PlotArea;

src/PhpPresentation/Shape/Chart/Axis.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,6 @@
1818
namespace PhpOffice\PhpPresentation\Shape\Chart;
1919

2020
use PhpOffice\PhpPresentation\ComparableInterface;
21-
use PhpOffice\PhpPresentation\Shape\Chart\Gridlines;
2221
use PhpOffice\PhpPresentation\Style\Font;
2322

2423
/**

src/PhpPresentation/Shape/Chart/Marker.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,6 @@
1717

1818
namespace PhpOffice\PhpPresentation\Shape\Chart;
1919

20-
use PhpOffice\PhpPresentation\ComparableInterface;
21-
2220
/**
2321
* \PhpOffice\PhpPresentation\Shape\Chart\Axis
2422
*/

src/PhpPresentation/Shape/Drawing/File.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,8 +2,6 @@
22

33
namespace PhpOffice\PhpPresentation\Shape\Drawing;
44

5-
use SplFileInfo;
6-
75
class File extends AbstractDrawingAdapter
86
{
97
/**

src/PhpPresentation/Shape/Table.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@
1717

1818
namespace PhpOffice\PhpPresentation\Shape;
1919

20-
use PhpOffice\PhpPresentation\AbstractShape;
2120
use PhpOffice\PhpPresentation\ComparableInterface;
2221
use PhpOffice\PhpPresentation\Shape\Table\Row;
2322

src/PhpPresentation/Writer/ODPresentation.php

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,6 @@
2121
use PhpOffice\PhpPresentation\HashTable;
2222
use PhpOffice\PhpPresentation\PhpPresentation;
2323
use PhpOffice\PhpPresentation\Shape\AbstractDrawing;
24-
use PhpOffice\PhpPresentation\Shape\Group;
2524
use PhpOffice\PhpPresentation\Shape\Table;
2625
use DirectoryIterator;
2726

src/PhpPresentation/Writer/PowerPoint2007.php

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,8 +23,6 @@
2323
use PhpOffice\PhpPresentation\PhpPresentation;
2424
use PhpOffice\PhpPresentation\Shape\AbstractDrawing;
2525
use PhpOffice\PhpPresentation\Shape\Chart as ChartShape;
26-
use PhpOffice\PhpPresentation\Shape\Drawing\AbstractDrawingAdapter;
27-
use PhpOffice\PhpPresentation\Shape\Group;
2826
use PhpOffice\PhpPresentation\Shape\Table;
2927
use PhpOffice\PhpPresentation\Writer\PowerPoint2007\LayoutPack\AbstractLayoutPack;
3028
use PhpOffice\PhpPresentation\Writer\PowerPoint2007\LayoutPack\PackDefault;

src/PhpPresentation/Writer/PowerPoint2007/PptCharts.php

Lines changed: 10 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -2006,19 +2006,16 @@ protected function writeAxis(XMLWriter $objWriter, Chart\Axis $oAxis, $typeAxis)
20062006
return;
20072007
}
20082008

2009-
switch ($typeAxis) {
2010-
case Chart\Axis::AXIS_X:
2011-
$mainElement = 'c:catAx';
2012-
$axIdVal = '52743552';
2013-
$axPosVal = 'b';
2014-
$crossAxVal = '52749440';
2015-
break;
2016-
case Chart\Axis::AXIS_Y:
2017-
$mainElement = 'c:valAx';
2018-
$axIdVal = '52749440';
2019-
$axPosVal = 'l';
2020-
$crossAxVal = '52743552';
2021-
break;
2009+
if ($typeAxis == Chart\Axis::AXIS_X) {
2010+
$mainElement = 'c:catAx';
2011+
$axIdVal = '52743552';
2012+
$axPosVal = 'b';
2013+
$crossAxVal = '52749440';
2014+
} else {
2015+
$mainElement = 'c:valAx';
2016+
$axIdVal = '52749440';
2017+
$axPosVal = 'l';
2018+
$crossAxVal = '52743552';
20222019
}
20232020

20242021
// $mainElement

0 commit comments

Comments
 (0)