3 final class AphrontFormSubmitControl
extends AphrontFormControl
{
5 private $buttons = array();
6 private $sigils = array();
8 public function addCancelButton($href, $label = null) {
10 $label = pht('Cancel');
12 $button = id(new PHUIButtonView())
16 ->setColor(PHUIButtonView
::GREY
);
17 $this->addButton($button);
21 public function addButton(PHUIButtonView
$button) {
22 $this->buttons
[] = $button;
26 public function addSigil($sigil) {
27 $this->sigils
[] = $sigil;
31 protected function getCustomControlClass() {
32 return 'aphront-form-control-submit';
35 protected function renderInput() {
36 $submit_button = null;
37 if ($this->getValue()) {
40 $sigils = $this->sigils
;
45 $submit_button = javelin_tag(
49 'name' => '__submit__',
51 'disabled' => $this->getDisabled() ?
'disabled' : null,