r54850 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r54849‎ | r54850 | r54851 >
Date:14:00, 12 August 2009
Author:siebrand
Status:deferred
Tags:
Comment:
* inactive new style magic words support for SemanticMediaWiki
* add localisation support for SemanticMediaWiki magic in Translate
Modified paths:
  • /trunk/extensions/SemanticMediaWiki/includes/SMW_GlobalFunctions.php (modified) (history)
  • /trunk/extensions/SemanticMediaWiki/languages/SMW_Magic.php (added) (history)
  • /trunk/extensions/SemanticMediaWiki/languages/SMW_Messages.php (modified) (history)
  • /trunk/extensions/Translate/groups/mediawiki-defines.txt (modified) (history)

Diff [purge]

Index: trunk/extensions/SemanticMediaWiki/includes/SMW_GlobalFunctions.php
@@ -101,6 +101,7 @@
102102 $smwgNamespace = $namespace;
103103 }
104104 $wgExtensionFunctions[] = 'smwfSetupExtension';
 105+ // FIXME: Can be removed when new style magic words are used (introduced in r52503)
105106 $wgHooks['LanguageGetMagic'][] = 'smwfAddMagicWords'; // setup names for parser functions (needed here)
106107 $wgExtensionMessagesFiles['SemanticMediaWiki'] = $smwgIP . '/languages/SMW_Messages.php'; // register messages (requires MW=>1.11)
107108
@@ -403,6 +404,7 @@
404405 /***** language settings *****/
405406 /**********************************************/
406407
 408+ // FIXME: Can be removed when new style magic words are used (introduced in r52503)
407409 /**
408410 * Set up (possibly localised) names for SMW's parser functions.
409411 */
Index: trunk/extensions/SemanticMediaWiki/languages/SMW_Messages.php
@@ -8,6 +8,9 @@
99 * @ingroup SMWLanguage
1010 */
1111
 12+// FIXME: Can be enabled when new style magic words are used (introduced in r52503)
 13+// require_once( dirname( __FILE__ ) . '/SMW_Magic.php' );
 14+
1215 $messages = array();
1316
1417 /** English
Index: trunk/extensions/SemanticMediaWiki/languages/SMW_Magic.php
@@ -0,0 +1,15 @@
 2+<?php
 3+
 4+$magicWords = array();
 5+
 6+$magicWords['en'] = array(
 7+ 'ask' => array( 0, 'ask' );
 8+ 'show' => array( 0, 'show' );
 9+ 'info' => array( 0, 'info' );
 10+ 'concept' => array( 0, 'concept' );
 11+ 'set' => array( 0, 'set' );
 12+ 'set_recurring_event' => array( 0, 'set_recurring_event' );
 13+ 'declare' => array( 0, 'declare' );
 14+ 'SMW_NOFACTBOX' => array( 0, '__NOFACTBOX__' );
 15+ 'SMW_SHOWFACTBOX' => array( 0, '__SHOWFACTBOX__' );
 16+);
Property changes on: trunk/extensions/SemanticMediaWiki/languages/SMW_Magic.php
___________________________________________________________________
Name: svn:eol-style
117 + native
Name: svn:keywords
218 + Id
Index: trunk/extensions/Translate/groups/mediawiki-defines.txt
@@ -830,6 +830,7 @@
831831 Semantic MediaWiki
832832 file = SemanticMediaWiki/languages/SMW_Messages.php
833833 aliasfile = SemanticMediaWiki/languages/SMW_Aliases.php
 834+magicfile = SemanticMediaWiki/languages/SMW_Magic.php
834835 descmsg = smw-desc
835836 ignored = smw_ask_doculink, smw_service_online_maps, smw_uri_blacklist
836837 optional = smw_rss_link, smw_decseparator, smw_kiloseparator

Follow-up revisions

RevisionCommit summaryAuthorDate
r54858Fix syntax error from r54850siebrand14:18, 12 August 2009

Status & tagging log