25 if ( isset( $info[
'buttonclass'] ) ) {
26 $this->mButtonClass = $info[
'buttonclass'];
28 if ( isset( $info[
'buttonid'] ) ) {
29 $this->mButtonId = $info[
'buttonid'];
31 if ( isset( $info[
'buttonname'] ) ) {
32 $this->mButtonName = $info[
'buttonname'];
34 if ( isset( $info[
'buttondefault'] ) ) {
35 $this->mButtonValue = $info[
'buttondefault'];
37 if ( isset( $info[
'buttontype'] ) ) {
38 $this->mButtonType = $info[
'buttontype'];
40 if ( isset( $info[
'buttonflags'] ) ) {
41 $this->mButtonFlags = $info[
'buttonflags'];
43 parent::__construct( $info );
52 return Html::input( $this->mButtonName, $this->mButtonValue, $this->mButtonType, $attr );
56 return new OOUI\ButtonInputWidget( [
57 'name' => $this->mButtonName,
58 'value' => $this->mButtonValue,
59 'type' => $this->mButtonType,
60 'label' => $this->mButtonValue,
61 'flags' => $this->mButtonFlags,
62 ] + OOUI\Element::configFromHtmlAttributes(