r113101 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r113100‎ | r113101 | r113102 >
Date:22:50, 5 March 2012
Author:foxtrott
Status:deferred
Tags:
Comment:
bugfix (SF cleans out modules of parsed forms)
Modified paths:
  • /trunk/extensions/SemanticForms/includes/SF_FormPrinter.php (modified) (history)
  • /trunk/extensions/SemanticForms/includes/SF_FormUtils.php (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticForms/includes/SF_FormPrinter.php
@@ -974,8 +974,8 @@
975975 if ( in_array( 'edittools', $free_text_components ) ) {
976976 // borrowed from EditPage::showEditTools()
977977 $options[] = 'parse';
978 - $edittools_text = wfMsgExt( 'edittools', array( 'parse' ), array( 'content' ) );
979 -
 978+ $edittools_text = $wgParser->recursiveTagParse( wfMsg( 'edittools', array( 'content' ) ) );
 979+
980980 $new_text .= <<<END
981981 <div class="mw-editTools">
982982 $edittools_text
@@ -1447,6 +1447,7 @@
14481448 $form_text .= $section;
14491449 }
14501450 $curPlaceholder = null;
 1451+// var_dump($wgParser->getOutput()->getModules());
14511452 } // end for
14521453
14531454 // Cleanup - everything has been browsed.
Index: trunk/extensions/SemanticForms/includes/SF_FormUtils.php
@@ -92,12 +92,15 @@
9393 }
9494
9595 static function minorEditInputHTML( $is_disabled, $label = null, $attrs = array() ) {
96 - global $sfgTabIndex, $wgUser;
 96+ global $sfgTabIndex, $wgUser, $wgParser;
9797
9898 $sfgTabIndex++;
9999 $checked = $wgUser->getOption( 'minordefault' );
100 - if ( $label == null )
101 - $label = wfMsgExt( 'minoredit', array( 'parseinline' ) );
 100+
 101+ if ( $label == null ) {
 102+ $label = $wgParser->recursiveTagParse( wfMsg( 'minoredit' ) );
 103+ }
 104+
102105 $tooltip = wfMsg( 'tooltip-minoredit' );
103106 $attrs += array(
104107 'id' => 'wpMinoredit',
@@ -117,7 +120,7 @@
118121 }
119122
120123 static function watchInputHTML( $is_disabled, $label = null, $attrs = array() ) {
121 - global $sfgTabIndex, $wgUser, $wgTitle;
 124+ global $sfgTabIndex, $wgUser, $wgTitle, $wgParser;
122125
123126 $sfgTabIndex++;
124127 $checked = "";
@@ -134,7 +137,7 @@
135138 $checked = true;
136139 }
137140 if ( $label == null )
138 - $label = wfMsgExt( 'watchthis', array( 'parseinline' ) );
 141+ $label = $wgParser->recursiveTagParse( wfMsg( 'watchthis' ) );
139142 $attrs += array(
140143 'id' => 'wpWatchthis',
141144 'accesskey' => wfMsg( 'accesskey-watch' ),
@@ -244,10 +247,10 @@
245248 }
246249
247250 static function cancelLinkHTML( $is_disabled, $label = null, $attr = array() ) {
248 - global $wgTitle;
 251+ global $wgTitle, $wgParser;
249252
250253 if ( $label == null ) {
251 - $label = wfMsgExt( 'cancel', array( 'parseinline' ) );
 254+ $label = $wgParser->recursiveTagParse( wfMsg( 'cancel' ) );
252255 }
253256 if ( $wgTitle == null ) {
254257 $cancel = '';