Special:Preferences/reset: Always use OOUI not the deprecated vform
authorJames D. Forrester <jforrester@wikimedia.org>
Wed, 30 May 2018 15:34:51 +0000 (08:34 -0700)
committerJforrester <jforrester@wikimedia.org>
Wed, 30 May 2018 16:25:07 +0000 (16:25 +0000)
Though it's "nice" to show this as a big red button to users, sadly
(a) vform is deprecated and shouldn't be used, and (b) the format's
restriction on button width intereferes with the length of the sole
control on this form, even without the prolix override expansion of
for which wikis' communities are wont to do.

Bug: T195977
Change-Id: Icc294bde1d3ed72837e7152003a2fbd522c9067d

includes/specials/SpecialPreferences.php

index 41ee353..0490cbb 100644 (file)
@@ -184,9 +184,7 @@ class SpecialPreferences extends SpecialPage {
 
                $context = new DerivativeContext( $this->getContext() );
                $context->setTitle( $this->getPageTitle( 'reset' ) ); // Reset subpage
-               $htmlForm = HTMLForm::factory(
-                       $this->oouiEnabled ? 'ooui' : 'vform', [], $context, 'prefs-restore'
-               );
+               $htmlForm = HTMLForm::factory( 'ooui', [], $context, 'prefs-restore' );
 
                $htmlForm->setSubmitTextMsg( 'restoreprefs' );
                $htmlForm->setSubmitDestructive();