60 public function __construct($stepNumber, $stepName, $stepType = self::TYPE_CURRENT)
64 $_GET[
'step'] = $stepNumber;
66 $this->completedStep =
false;
67 $this->stepType = $stepType;
68 $this->stepNumber = $stepNumber;
70 if ( $stepType == self::TYPE_CURRENT )
72 $stepLabel =
new MDiv(
'stepLabel_' . $stepNumber, $stepName, self::CURRENT_LABEL_STYLE);
73 $stepImage =
new MDiv(
'stepImage_' . $stepNumber,
'', self::CURRENT_ICON_STYLE);
74 $stepDescription =
new MDiv(
'stepDescription_' . $stepNumber, _M(
'Current step'), self::STATUS_LABEL_STYLE);
76 elseif ( $stepType == self::TYPE_NEXT )
78 $stepLabel =
new MDiv(
'stepLabel_' . $stepNumber, $stepName, self::LABEL_STYLE);
79 $stepImage =
new MDiv(
'stepImage_' . $stepNumber,
'', self::NEXT_ICON_STYLE);
80 $stepDescription =
new MDiv(
'stepDescription_' . $stepNumber, _M(
'Pending step'), self::STATUS_LABEL_STYLE);
82 elseif ( $stepType == self::TYPE_PREVIOUS )
84 $stepLabel =
new MDiv(
'stepLabel_' . $stepNumber, $stepName, self::LABEL_STYLE);
85 $stepImage =
new MDiv(
'stepImage_' . $stepNumber,
'', self::PREVIOUS_ICON_STYLE);
86 $stepDescription =
new MDiv(
'stepDescription_' . $stepNumber, _M(
'Finished step'), self::STATUS_LABEL_STYLE);
87 $this->completedStep =
true;
90 $divLeft =
new MDiv(
'divLeft_' . $stepNumber, $stepImage, self::BUTTON_STYLE);
91 $divRight =
new MDiv(
'divRight_' . $stepNumber, $stepNumber, self::NUMBER_STYLE);
92 $div =
new MDiv(
'divStepInner_' . $stepNumber, array( $divRight, $divLeft, $stepDescription ),
'divStepInner');
94 parent::__construct(
'divStep_' . $stepNumber, array( $div, $stepLabel ));