HistoryAction: Use correct classes for buttons
authorPrateek Saxena <prtksxna@gmail.com>
Thu, 25 Sep 2014 01:46:16 +0000 (18:46 -0700)
committerPrateek Saxena <prtksxna@gmail.com>
Mon, 29 Sep 2014 20:45:09 +0000 (13:45 -0700)
Bug: 71141
Change-Id: I95ac411e7c06d3b7aec966527f196ef347f1c710

includes/actions/HistoryAction.php

index 8522e56..99006ed 100644 (file)
@@ -181,6 +181,10 @@ class HistoryAction extends FormlessAction {
 
                // Add the general form
                $action = htmlspecialchars( wfScript() );
+               $className = 'historysubmit mw-history-compareselectedversions-button';
+               if ( $config->get( 'UseMediaWikiUIEverywhere' ) ) {
+                       $className .= ' mw-ui-button mw-ui-progressive';
+               }
                $out->addHTML(
                        "<form action=\"$action\" method=\"get\" id=\"mw-history-searchform\">" .
                        Xml::fieldset(
@@ -196,7 +200,10 @@ class HistoryAction extends FormlessAction {
                        ) . '&#160;' .
                        ( $tagSelector ? ( implode( '&#160;', $tagSelector ) . '&#160;' ) : '' ) .
                        $checkDeleted .
-                       Xml::submitButton( $this->msg( 'allpagessubmit' )->text() ) . "\n" .
+                       Xml::submitButton(
+                               $this->msg( 'allpagessubmit' )->text(),
+                               array( 'class' => $className )
+                       ) . "\n" .
                        '</fieldset></form>'
                );
 
@@ -486,7 +493,7 @@ class HistoryPager extends ReverseChronologicalPager {
                $this->buttons = '<div>';
                $className = 'historysubmit mw-history-compareselectedversions-button';
                if ( $this->getConfig()->get( 'UseMediaWikiUIEverywhere' ) ) {
-                       $className .= ' mw-ui-button mw-ui-constructive';
+                       $className .= ' mw-ui-button';
                }
                $this->buttons .= $this->submitButton( $this->msg( 'compareselectedversions' )->text(),
                        array( 'class' => $className )