Differential D350 Diff 976 branches/5.2.x/core/units/general/libchart/classes/view/color/ColorSet.php
Changeset View
Changeset View
Standalone View
Standalone View
branches/5.2.x/core/units/general/libchart/classes/view/color/ColorSet.php
Show All 29 Lines | |||||
public $shadowColorList; | public $shadowColorList; | ||||
/** | /** | ||||
* ColorSet constructor. | * ColorSet constructor. | ||||
* | * | ||||
* @param $shadowFactor Shadow factor | * @param $shadowFactor Shadow factor | ||||
* @param $colorArray Colors as an array | * @param $colorArray Colors as an array | ||||
*/ | */ | ||||
public function LibchartColorSet($colorList, $shadowFactor) { | public function __construct($colorList, $shadowFactor) { | ||||
$this->colorList = $colorList; | $this->colorList = $colorList; | ||||
$this->shadowColorList = array(); | $this->shadowColorList = array(); | ||||
// Generate the shadow color set | // Generate the shadow color set | ||||
foreach ($colorList as $color) { | foreach ($colorList as $color) { | ||||
$shadowColor = $color->getShadowColor($shadowFactor); | $shadowColor = $color->getShadowColor($shadowFactor); | ||||
array_push($this->shadowColorList, $shadowColor); | array_push($this->shadowColorList, $shadowColor); | ||||
Show All 29 Lines | |||||
/** | /** | ||||
* Returns the current shadow color. | * Returns the current shadow color. | ||||
* | * | ||||
* @return Current shadow color | * @return Current shadow color | ||||
*/ | */ | ||||
public function currentShadowColor() { | public function currentShadowColor() { | ||||
return current($this->shadowColorList); | return current($this->shadowColorList); | ||||
} | } | ||||
} | } | ||||
No newline at end of file |