[MediaWiki-CVS] SVN: [68870] trunk/phase3/maintenance/updaters.inc
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68870 Revision: 68870 Author: reedy Date: 2010-07-02 06:52:20 + (Fri, 02 Jul 2010) Log Message: --- Remove some whitespace, and fixup if braces in postgres section of updaters.inc Fix minor message typo also Modified Paths: -- trunk/phase3/maintenance/updaters.inc Modified: trunk/phase3/maintenance/updaters.inc === --- trunk/phase3/maintenance/updaters.inc 2010-07-02 04:31:10 UTC (rev 68869) +++ trunk/phase3/maintenance/updaters.inc 2010-07-02 06:52:20 UTC (rev 68870) @@ -283,8 +283,6 @@ } } - - function add_field( $table, $field, $patch, $fullpath = false ) { global $wgDatabase; if ( !$wgDatabase->tableExists( $table ) ) { @@ -499,7 +497,6 @@ wfOut( "Done.\n" ); } - function do_user_update() { global $wgDatabase; if ( $wgDatabase->fieldExists( 'user', 'user_emailauthenticationtimestamp' ) ) { @@ -1177,7 +1174,6 @@ flush(); } - wfOut( "Deleting old default messages (this may take a long time!)..." ); if ( !defined( 'MW_NO_SETUP' ) ) { define( 'MW_NO_SETUP', true ); @@ -1405,8 +1401,6 @@ } } - - /*** * Start PG stuff * TODO: merge with above @@ -1423,8 +1417,9 @@ $res = $wgDatabase->query( sprintf( $q, $wgDatabase->addQuotes( $table ), $wgDatabase->addQuotes( $wgDBmwschema ) ) ); - if ( !$res ) + if ( !$res ) { return null; + } $cols = array(); while ( $r = $wgDatabase->fetchRow( $res ) ) { @@ -1451,8 +1446,9 @@ $res = $wgDatabase->query( sprintf( $q, $wgDatabase->addQuotes( $wgDBmwschema ), $wgDatabase->addQuotes( $idx ) ) ); - if ( !$res ) + if ( !$res ) { return null; + } if ( !( $r = $wgDatabase->fetchRow( $res ) ) ) { $wgDatabase->freeResult( $res ); return null; @@ -1472,8 +1468,9 @@ AND attrelid=pg_class.oid END; $r2 = $wgDatabase->query( sprintf( $query, $rid ) ); - if ( !$r2 ) + if ( !$r2 ) { return null; + } if ( !( $row2 = $wgDatabase->fetchRow( $r2 ) ) ) { $wgDatabase->freeResult( $r2 ); return null; @@ -1505,8 +1502,9 @@ $r = $wgDatabase->query( sprintf( $q, $wgDatabase->addQuotes( $wgDBmwschema ), $wgDatabase->addQuotes( $fkey ) ) ); - if ( !( $row = $wgDatabase->fetchRow( $r ) ) ) + if ( !( $row = $wgDatabase->fetchRow( $r ) ) ) { return null; + } return $row[0]; } @@ -1523,8 +1521,9 @@ $wgDatabase->addQuotes( $table ), $wgDatabase->addQuotes( $rule ) ) ); $row = $wgDatabase->fetchRow( $r ); - if ( !$row ) + if ( !$row ) { return null; + } $d = $row[0]; $wgDatabase->freeResult( $r ); return $d; @@ -1540,8 +1539,9 @@ $wgShowExceptionDetails = 1; # Just in case their LocalSettings.php does not have this: - if ( !isset( $wgDBmwschema ) ) + if ( !isset( $wgDBmwschema ) ) { $wgDBmwschema = 'mediawiki'; + } # Verify that this user is configured correctly $safeuser = $wgDatabase->addQuotes( $wgDBuser ); @@ -1554,8 +1554,7 @@ } if ( !array_key_exists( 'search_path', $conf ) ) { $search_path = ''; - } - else { + } else { $search_path = $conf['search_path']; } if ( strpos( $search_path, $wgDBmwschema ) === false ) { @@ -1570,8 +1569,7 @@ if ( array_key_exists( 'search_path', $conf ) === false || $search_path != $conf['search_path'] ) { $wgDatabase->doQuery( "ALTER USER $wgDBuser SET search_path = $search_path" ); $wgDatabase->doQuery( "SET search_path = $search_path" ); - } - else { + } else { $path = $conf['search_path']; wfOut( "... search_path for user \"$wgDBuser\" looks correct ($path)\n" ); } @@ -1586,8 +1584,7 @@ wfOut( "Setting $key to '$value' for user \"$wgDBuser\"\n" ); $wgDatabase->doQuery( "ALTER USER $wgDBuser SET $key = '$value'" ); $wgDatabase->doQuery( "SET $key = '$value'" ); - } - else { + } else { wfOut( "... default value of \"$key\" is correctly set to \"$value\" for user \"$wgDBuser\"\n" ); } } @@ -1857,12 +1854,10 @@
[MediaWiki-CVS] SVN: [68869] trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/ nbproject/private/private.xml
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68869 Revision: 68869 Author: bhagya Date: 2010-07-02 04:31:10 + (Fri, 02 Jul 2010) Log Message: --- Modified Paths: -- trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/nbproject/private/private.xml Modified: trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/nbproject/private/private.xml === --- trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/nbproject/private/private.xml 2010-07-02 04:16:46 UTC (rev 68868) +++ trunk/testing/selenium/UsabilityInitiative/WikiAutomationTC/nbproject/private/private.xml 2010-07-02 04:31:10 UTC (rev 68869) @@ -7,7 +7,7 @@ testCases/WikiDialogs_TC.php -337 +413 ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68868] trunk/phase3/includes
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68868 Revision: 68868 Author: philip Date: 2010-07-02 04:16:46 + (Fri, 02 Jul 2010) Log Message: --- Update the Chinese conversion tables. Modified Paths: -- trunk/phase3/includes/ZhConversion.php trunk/phase3/includes/zhtable/simp2trad.manual trunk/phase3/includes/zhtable/simpphrases.manual trunk/phase3/includes/zhtable/toSimp.manual trunk/phase3/includes/zhtable/toTrad.manual trunk/phase3/includes/zhtable/trad2simp.manual trunk/phase3/includes/zhtable/tradphrases.manual trunk/phase3/includes/zhtable/tradphrases_exclude.manual Modified: trunk/phase3/includes/ZhConversion.php === --- trunk/phase3/includes/ZhConversion.php 2010-07-02 03:17:39 UTC (rev 68867) +++ trunk/phase3/includes/ZhConversion.php 2010-07-02 04:16:46 UTC (rev 68868) @@ -82,6 +82,7 @@ '䴗' => '鶪', '䴘' => '鷈', '䴙' => '鷿', +'䶮' => '龑', '万' => '萬', '与' => '與', '专' => '專', @@ -2746,34 +2747,54 @@ '𫛶' => '鶒', '𫛸' => '鶗', '' => '棡', +'0只支持' => '0只支持', +'0只支援' => '0只支援', '0多只' => '0多隻', '0天后' => '0天後', '0只' => '0隻', '0余' => '0餘', +'1只支持' => '1只支持', +'1只支援' => '1只支援', '1天后' => '1天後', '1只' => '1隻', '1余' => '1餘', +'2只支持' => '2只支持', +'2只支援' => '2只支援', '2天后' => '2天後', '2只' => '2隻', '2余' => '2餘', +'3只支持' => '3只支持', +'3只支援' => '3只支援', '3天后' => '3天後', '3只' => '3隻', '3余' => '3餘', +'4只支持' => '4只支持', +'4只支援' => '4只支援', '4天后' => '4天後', '4只' => '4隻', '4余' => '4餘', +'5只支持' => '5只支持', +'5只支援' => '5只支援', '5天后' => '5天後', '5只' => '5隻', '5余' => '5餘', +'6只支持' => '6只支持', +'6只支援' => '6只支援', '6天后' => '6天後', '6只' => '6隻', '6余' => '6餘', +'7只支持' => '7只支持', +'7只支援' => '7只支援', '7天后' => '7天後', '7只' => '7隻', '7余' => '7餘', +'8只支持' => '8只支持', +'8只支援' => '8只支援', '8天后' => '8天後', '8只' => '8隻', '8余' => '8餘', +'9只支持' => '9只支持', +'9只支援' => '9只支援', '9天后' => '9天後', '9只' => '9隻', '9余' => '9餘', @@ -2950,6 +2971,7 @@ '世纪钟表' => '世紀鐘錶', '丢丑' => '丟醜', '并不准' => '並不准', +'并不准确' => '並不準確', '并存着' => '並存著', '并曰入淀' => '並曰入澱', '并发动' => '並發動', @@ -3206,8 +3228,8 @@ '于佳卉' => '于佳卉', '于伟国' => '于偉國', '于偉國' => '于偉國', +'于光远' => '于光遠', '于光遠' => '于光遠', -'于光远' => '于光遠', '于克-蘭多縣' => '于克-蘭多縣', '于克-兰多县' => '于克-蘭多縣', '于克勒' => '于克勒', @@ -3451,6 +3473,7 @@ '伊斯兰教历史' => '伊斯蘭教歷史', '伊斯兰历' => '伊斯蘭曆', '伊斯兰历史' => '伊斯蘭歷史', +'伊尔汗历表' => '伊爾汗曆表', '伊郁' => '伊鬱', '伏几' => '伏几', '伐罪吊民' => '伐罪弔民', @@ -4031,6 +4054,7 @@ '分半钟' => '分半鐘', '分多钟' => '分多鐘', '分子钟' => '分子鐘', +'分子云' => '分子雲', '分布圖' => '分布圖', '分布图' => '分布圖', '分布于' => '分布於', @@ -4370,8 +4394,12 @@ '后丰' => '后豐', '后豐' => '后豐', '后里' => '后里', +'后发FK型星' => '后髮FK型星', +'后髮FK型星' => '后髮FK型星', '后髮座' => '后髮座', '后发座' => '后髮座', +'后发星系团' => '后髮星系團', +'后髮星系團' => '后髮星系團', '吐哺捉发' => '吐哺捉髮', '吐哺握发' => '吐哺握髮', '向往来' => '向往來', @@ -4527,6 +4555,7 @@ '在于' => '在於', '地占' => '地佔', '地克制' => '地剋制', +'地心历表' => '地心曆表', '地方志' => '地方志', '地志' => '地誌', '地丑德齐' => '地醜德齊', @@ -4666,7 +4695,11 @@ '天地志狼' => '天地志狼', '天地为范' => '天地為範', '天干地支' => '天干地支', +'天后来' => '天後來', +'天后半' => '天後半', +'天后天' => '天後天', '天文学钟' => '天文學鐘', +'天文历表' => '天文曆表', '天文钟' => '天文鐘', '天历' => '天曆', '天历史' => '天歷史', @@ -4865,6 +4898,8 @@ '尸居余气' => '尸居餘氣', '尸祝' => '尸祝', '尸禄' => '尸祿', +'尸罗精舍' => '尸羅精舍', +'尸羅精舍' => '尸羅精舍', '尸臣' => '尸臣', '尸谏' => '尸諫', '尸魂界' => '尸魂界', @@ -5130,6 +5165,7 @@ '形单影只' => '形單影隻', '形影相吊' => '形影相弔', '形于' => '形於', +'彭于晏' => '彭于晏', '影后' => '影后', '仿佛' => '彷彿', '役于' => '役於', @@ -5152,6 +5188,7 @@ '从里到外' => '從裡到外', '从里向外' => '從裡向外', '复始' => '復始', +'复活节历表' => '復活節曆表', '征人' => '徵人', '征令' => '徵令', '征占' => '徵佔', @@ -5982,6 +6019,7 @@ '旗杆' => '旗杆', '日占' => '日佔', '日子里' => '日子裡', +'日心历表' => '日心曆表', '日晒' => '日晒', '日历' => '日曆', '日历史' => '日歷史', @@ -6076,6 +6114,7 @@ '会里' => '會裡', '月历' => '月曆', '月历史' => '月歷史', +'月球历表' => '月球曆表', '月离于毕' => '月離於畢', '月面' => '月面', '月丽于箕' => '月麗於箕', @@ -6134,12 +6173,16 @@ '村庄' => '村莊', '村落发' => '村落發', '村里' => '村裡', +'村里长' => '村里長', +'村里長' => '村里長', '杜老志道' => '杜老誌道', '杞宋无征' => '杞宋無徵', '束发' => '束髮', '杯干' => '杯乾', '杯面' => '杯麵', '杰伦' => '杰倫', +'杰威爾音樂' => '杰威爾音樂', +'杰威尔音乐' => '杰威爾音樂', '杰特' => '杰特', '东周钟' => '東周鐘', '东岳' => '東嶽', @@ -6198,6 +6241,8 @@ '棺材里' => '棺材裡', '植发' => '植髮', '椰枣干' => '椰棗乾', +'楊雅筑' => '楊雅筑', +'杨雅筑' => '楊雅筑', '楚庄问鼎' => '楚莊問鼎', '楚庄王' => '楚莊王', '楚庄绝缨' => '楚莊絕纓', @@ -6316,6 +6361,8 @@ '水来汤里去' => '水來湯裡去', '水准' => '水準', '水里' => '水裡', +'水里溪' => '水里溪', +'水里浊水溪' => '水里濁水溪', '水里鄉' => '水里鄉', '水里乡' => '水里鄉', '永历' => '永曆', @@ -6495,6 +6542,7 @@ '准会' => '準會', '准决赛' => '準決賽', '准的' => '準的', +'准直' => '準直', '准确' => '準確', '准线' => '準線', '准绳' => '準繩', @@ -6722,6 +6770,7 @@ '瑞征' => '瑞徵', '瑶签' => '瑤籤', '环游' => '環遊', +'瓷制' => '瓷製', '瓮安' => '甕安', '甚于' => '甚於', '甚么' => '甚麼', @@ -7064,6 +7113,7 @@ '竹几' => '竹几', '竹林之游' => '竹林之遊', '竹签' => '竹籤', +'竹制' => '竹製', '笑里藏刀' => '笑裡藏刀', '笨笨呆呆' => '笨笨呆呆', '第四出局' => '第四出局', @@ -7114,12 +7164,15 @@ '范字' => '範字', '范式' => '範式', '范性形变' => '範性形
[MediaWiki-CVS] SVN: [68867] trunk/extensions/CentralNotice/SpecialNoticeTemplate.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68867 Revision: 68867 Author: tstarling Date: 2010-07-02 03:17:39 + (Fri, 02 Jul 2010) Log Message: --- * Fixed code duplication from r67371, made a new pager subclass instead of copying code from Pager.php. Used ReverseChronologicalPager, since it was indeed reverse chronological. Note that the maximum limit (5000) is still in effect despite being removed here, Ryan copied that code out of WebRequest.php. * Fixed incorrect JS escaping added in r42857 * Moved wfMsg() calls out of the loop body * Replaced deprecated function ereg_replace() with preg_replace(). Modified Paths: -- trunk/extensions/CentralNotice/SpecialNoticeTemplate.php Modified: trunk/extensions/CentralNotice/SpecialNoticeTemplate.php === --- trunk/extensions/CentralNotice/SpecialNoticeTemplate.php2010-07-02 01:24:05 UTC (rev 68866) +++ trunk/extensions/CentralNotice/SpecialNoticeTemplate.php2010-07-02 03:17:39 UTC (rev 68867) @@ -6,36 +6,9 @@ } class SpecialNoticeTemplate extends UnlistedSpecialPage { - public $limitsShown = array( 20, 50, 100 ); - public $defaultLimit = 20; - public $mOffset, $mLimit; - protected $indexField = 'tmp_id'; - protected $mDb; + var $editable; - /* Functions */ - function __construct() { - // Initialize special page - global $wgRequest; - $this->mRequest = $wgRequest; - - # NB: the offset is quoted, not validated. It is treated as an - # arbitrary string to support the widest variety of index types. Be - # careful outputting it into HTML! - $this->mOffset = $this->mRequest->getText( 'offset' ); - - # Set the limit, default to 20, ignore User default - $limit = $this->mRequest->getInt( 'limit', 0 ); - if ( $limit <= 0 ) { - $limit = 20; - } - if ( $limit > 5000 ) { - $limit = 5000; # We have *some* limits... - } - $this->mLimit = $limit; - - $this->mDb = wfGetDB( DB_SLAVE ); - parent::__construct( 'NoticeTemplate' ); // Internationalization @@ -51,9 +24,6 @@ // Begin output $this->setHeaders(); - // Get current skin - $sk = $wgUser->getSkin(); - // Check permissions $this->editable = $wgUser->isAllowed( 'centralnotice-admin' ); @@ -109,7 +79,7 @@ } } - // Handle viewiing of a template in all languages + // Handle viewing of a template in all languages if ( $sub == 'view' && $wgRequest->getVal( 'wpUserLanguage' ) == 'all' ) { $template = $wgRequest->getVal( 'template' ); $this->showViewAvailable( $template ); @@ -147,22 +117,14 @@ * Show a list of available templates. Newer templates are shown first. */ function showList() { - global $wgOut, $wgUser, $wgRequest, $wgLang; + global $wgOut, $wgUser; $sk = $wgUser->getSkin(); - - // Templates - $offset = $wgRequest->getVal( 'offset' ); - if ( $wgRequest->getVal( 'limit' ) ) { - $limit = $wgRequest->getVal( 'limit' ); + $pager = new NoticeTemplatePager( $this ); + if ( !$pager->getNumRows() ) { + $htmlOut = Xml::element( 'p', null, wfMsg( 'centralnotice-no-templates' ) ); } else { - $limit = $this->defaultLimit; - } - - $templates = $this->queryTemplates($offset, $limit); - $htmlOut = ''; - if ( count( $templates ) > 0 ) { - + $htmlOut = ''; if ( $this->editable ) { $htmlOut .= Xml::openElement( 'form', array( @@ -171,104 +133,27 @@ ) ); } + $htmlOut .= Xml::fieldset( wfMsg( 'centralnotice-available-templates' ) ); - $totalTemplateCount = $this->getTemplateCount(); - if ( $totalTemplateCount > count( $templates ) || $totalTemplateCount > 20 ) { - //Show pagination links - $opts = array( 'parsemag', 'escapenoentities' ); - $linkTexts = array( -
[MediaWiki-CVS] SVN: [68863] branches/resourceloader/phase3/resources
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68863 Revision: 68863 Author: tparscal Date: 2010-07-02 00:13:55 + (Fri, 02 Jul 2010) Log Message: --- This is still not working quite right But I need to go home. Modified Paths: -- branches/resourceloader/phase3/resources/core/mw/mw.loader.js branches/resourceloader/phase3/resources/test/bar.js branches/resourceloader/phase3/resources/test/baz.js branches/resourceloader/phase3/resources/test/buz.js branches/resourceloader/phase3/resources/test/foo.js branches/resourceloader/phase3/resources/test/index.html branches/resourceloader/phase3/resources/test/test.js Modified: branches/resourceloader/phase3/resources/core/mw/mw.loader.js === --- branches/resourceloader/phase3/resources/core/mw/mw.loader.js 2010-07-01 23:59:58 UTC (rev 68862) +++ branches/resourceloader/phase3/resources/core/mw/mw.loader.js 2010-07-02 00:13:55 UTC (rev 68863) @@ -29,6 +29,8 @@ var batch = []; // True after document ready occurs var ready = false; + // Unique identification for generic queue item names + var unique = 0; /* Private Functions */ @@ -80,20 +82,18 @@ * Processes the queue, loading and executing when things when ready. */ this.work = function() { - for ( var q = 0; q < queue.length; q++ ) { - for ( var p = 0; p < queue[q].pending.length; p++ ) { + for ( var q in queue ) { + for ( var p in queue[q].pending ) { var requirement = queue[q].pending[p]; // If it's not in the registry yet, we're certainly not ready to execute - if ( - typeof registry[requirement] !== 'undefined' && - typeof registry[requirement].state !== 'undefined' - ) { + if ( requirement in registry && 'state' in registry[requirement] ) { // Take action, or not switch ( registry[requirement].state ) { case 'registered': // Load (add to batch) if ( batch.indexOf( requirement ) == -1 ) { batch[batch.length] = requirement; + registry[requirement].state = 'loading'; } break; case 'loading': @@ -104,28 +104,34 @@ break; case 'ready': // This doesn't belong in the queue item's pending list - queue[q].pending.splice( p, 1 ); - // Correct the array index - p--; + delete queue[q].pending[p]; break; } } + /* + if ( requirement in queue ) { + // Wait (do nothing...) + console.log( queue ); + continue; + } +*/ } // If all pending requirements have been satisfied, we're ready to execute the callback if ( queue[q].pending.length == 0 ) { queue[q].callback(); // Clean up the queue - queue.splice( q, 1 ); + delete queue[q]; } } // Handle the batch only when ready if ( batch.length && ready ) { + // Always order module alphabetically to help reduce cache misses for otherwise identical content + batch.sort(); + console.log( batch ); // It may be more performant to do this with an Ajax call, but that's limited to same-domain, so we can
[MediaWiki-CVS] SVN: [68866] trunk/extensions/UploadWizard
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68866 Revision: 68866 Author: neilk Date: 2010-07-02 01:24:05 + (Fri, 02 Jul 2010) Log Message: --- page 3 validation mostly working, many trivial changes to pass JS linting Modified Paths: -- trunk/extensions/UploadWizard/UploadWizard.i18n.php trunk/extensions/UploadWizard/UploadWizardPage.js trunk/extensions/UploadWizard/js/mw.UploadWizard.js trunk/extensions/UploadWizard/styles/uploadWizard.css Modified: trunk/extensions/UploadWizard/UploadWizard.i18n.php === --- trunk/extensions/UploadWizard/UploadWizard.i18n.php 2010-07-02 00:45:27 UTC (rev 68865) +++ trunk/extensions/UploadWizard/UploadWizard.i18n.php 2010-07-02 01:24:05 UTC (rev 68866) @@ -140,7 +140,7 @@ Make it longer than $1 {{PLURAL:$1|character|characters}}.', 'mwe-upwiz-error-bad-chars' => 'This field contains symbols that are not allowed. Please do not use wikitext or HTML here.', - + 'mwe-upwiz-error-date' => 'Please enter a valid date in -MM-DD format, or pick a date from the popup calendar.', /* LICENSES */ /* surprisingly we don't seem to have strings for these yet */ 'mwe-upwiz-license-cc-by-sa-3.0' => 'Creative Commons Attribution ShareAlike 3.0', Modified: trunk/extensions/UploadWizard/UploadWizardPage.js === --- trunk/extensions/UploadWizard/UploadWizardPage.js 2010-07-02 00:45:27 UTC (rev 68865) +++ trunk/extensions/UploadWizard/UploadWizardPage.js 2010-07-02 01:24:05 UTC (rev 68866) @@ -42,6 +42,11 @@ minAuthorLength: 2, maxSourceLength: 200, minSourceLength: 5, + maxTitleLength: 200, + minTitleLength: 5, + maxDescriptionLength: 4096, + minDescriptionLength: 5, + maxOtherInformationLength: 4096, maxSimultaneousConnections: 2, maxUploads: 10, Modified: trunk/extensions/UploadWizard/js/mw.UploadWizard.js === --- trunk/extensions/UploadWizard/js/mw.UploadWizard.js 2010-07-02 00:45:27 UTC (rev 68865) +++ trunk/extensions/UploadWizard/js/mw.UploadWizard.js 2010-07-02 01:24:05 UTC (rev 68866) @@ -181,20 +181,20 @@ if ( remainingTime !== null ) { var t = mw.seconds2Measurements( parseInt( remainingTime / 1000, 10 ) ); var timeString; - if (t.hours == 0) { - if (t.minutes == 0) { - if (t.seconds == 0) { + if (t.hours === 0) { + if (t.minutes === 0) { + if (t.seconds === 0) { timeString = gM( 'mwe-upwiz-finished' ); } else { timeString = gM( 'mwe-upwiz-secs-remaining', t.seconds ); } } else { - timeString = gM( 'mwe-upwiz-mins-secs-remaining', t.minutes, t.seconds ) + timeString = gM( 'mwe-upwiz-mins-secs-remaining', t.minutes, t.seconds ); } } else { timeString = gM( 'mwe-upwiz-hrs-mins-secs-remaining', t.hours, t.minutes, t.seconds ); } - _this.$selector.find( '.mwe-upwiz-etr' ).html( timeString ) + _this.$selector.find( '.mwe-upwiz-etr' ).html( timeString ); } }, @@ -265,7 +265,7 @@ var $input = $j( '' ) .attr( { id: id, name: name, type: 'checkbox', value: template } ) // we use the selector because events can't be unbound unless they're in the DOM. - .click( function() { _this.$selector.trigger( 'changeLicenses' ) } ) + .click( function() { _this.$selector.trigger( 'changeLicenses' ); } ); _this.inputs.push( $input ); _this.$selector.append( $input, @@ -316,8 +316,8 @@ */ getTemplates: function() { return $j( this.inputs ) - .filter( function() { return this.is( ':checked' ) } ) - .map( function() { return this.val() } ); + .filter( function() { return this.is( ':checked' ); } ) + .map( function() { return this.val(); } ); }, /** @@ -575,6 +575,7 @@
[MediaWiki-CVS] SVN: [68862] branches/resourceloader/phase3/includes/ResourceLoader.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68862 Revision: 68862 Author: tparscal Date: 2010-07-01 23:59:58 + (Thu, 01 Jul 2010) Log Message: --- Debug core stuff should only come through with core stuff... Modified Paths: -- branches/resourceloader/phase3/includes/ResourceLoader.php Modified: branches/resourceloader/phase3/includes/ResourceLoader.php === --- branches/resourceloader/phase3/includes/ResourceLoader.php 2010-07-01 23:54:35 UTC (rev 68861) +++ branches/resourceloader/phase3/includes/ResourceLoader.php 2010-07-01 23:59:58 UTC (rev 68862) @@ -138,14 +138,13 @@ $retval .= file_get_contents( $script ); } } - $retval .= $this->getLoaderJS(); - } - if ( $this->useDebugMode ) { - // TODO: file_get_contents() errors? - // TODO: CACHING! - foreach ( self::$debugScripts as $script ) { - if ( file_exists( $script ) ) { - $retval .= file_get_contents( $script ); + if ( $this->useDebugMode ) { + // TODO: file_get_contents() errors? + // TODO: CACHING! + foreach ( self::$debugScripts as $script ) { + if ( file_exists( $script ) ) { + $retval .= file_get_contents( $script ); + } } } $retval .= $this->getLoaderJS(); @@ -190,7 +189,7 @@ $retval .= "mw.loader.implement( '$module', function() { $script }, '$style', { $messages } );\n"; } - if ( $this->useJSMin ) { + if ( !$this->useDebugMode && $this->useJSMin ) { $retval = $this->jsMin( $retval ); } return $retval; ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68861] trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68861 Revision: 68861 Author: yaron Date: 2010-07-01 23:54:35 + (Thu, 01 Jul 2010) Log Message: --- Added myself as author Modified Paths: -- trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php Modified: trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php === --- trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php 2010-07-01 23:53:42 UTC (rev 68860) +++ trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php 2010-07-01 23:54:35 UTC (rev 68861) @@ -23,6 +23,7 @@ * http://www.gnu.org/copyleft/gpl.html * * @author Jeroen De Dauw + * @author Yaron Koren * @ingroup Maintenance */ ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68860] trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68860 Revision: 68860 Author: yaron Date: 2010-07-01 23:53:42 + (Thu, 01 Jul 2010) Log Message: --- Fixed path, changed class name, script only affects pages with no approved revision, script ignores pages in unhandled namespaces, changed output Modified Paths: -- trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php Modified: trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php === --- trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php 2010-07-01 23:51:38 UTC (rev 68859) +++ trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php 2010-07-01 23:53:42 UTC (rev 68860) @@ -1,7 +1,8 @@ mDescription = "Approve all current revisions"; + $this->mDescription = "Approve the current revision of all pages that do not yet have an approved revision."; } public function execute() { + global $wgTitle; $dbr = wfGetDB( DB_SLAVE ); @@ -49,8 +51,14 @@ while ( $page = $pages->fetchObject() ) { $title = Title::newFromID( $page->page_id ); - ApprovedRevs::setApprovedRevID( $title, $page->page_latest ); - $this->output( "\n" . wfTimestamp( TS_DB ) . ' Page ' . $title->getFullText() . ' now has ' . $page->page_latest . ' as approved revision.' ); + // some extensions, like Semantic Forms, need $wgTitle + // set as well + $wgTitle = $title; + if ( ! ApprovedRevs::hasUnsupportedNamespace( $title ) && + ! ApprovedRevs::hasApprovedRevision( $title ) ) { + ApprovedRevs::setApprovedRevID( $title, $page->page_latest ); + $this->output( wfTimestamp( TS_DB ) . ' Approved the last revision of page "' . $title->getFullText() . '".' ); + } } @@ -59,5 +67,5 @@ } -$maintClass = "ApproveRevisions"; -require_once( DO_MAINTENANCE ); \ No newline at end of file +$maintClass = "ApproveAllPages"; +require_once( DO_MAINTENANCE ); ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68859] trunk/extensions/ApprovedRevs/maintenance
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68859 Revision: 68859 Author: yaron Date: 2010-07-01 23:51:38 + (Thu, 01 Jul 2010) Log Message: --- Better name (I think) Added Paths: --- trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php Removed Paths: - trunk/extensions/ApprovedRevs/maintenance/approveRevisions.php Copied: trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php (from rev 68857, trunk/extensions/ApprovedRevs/maintenance/approveRevisions.php) === --- trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php (rev 0) +++ trunk/extensions/ApprovedRevs/maintenance/approveAllPages.php 2010-07-01 23:51:38 UTC (rev 68859) @@ -0,0 +1,63 @@ +http://www.gnu.org/copyleft/gpl.html + * + * @author Jeroen De Dauw + * @ingroup Maintenance + */ + +require_once( dirname( __FILE__ ) . '/../../maintenance/Maintenance.php' ); + +class ApproveRevisions extends Maintenance { + + public function __construct() { + parent::__construct(); + + $this->mDescription = "Approve all current revisions"; + } + + public function execute() { + + $dbr = wfGetDB( DB_SLAVE ); + + $pages = $dbr->select( + 'page', + array( + 'page_id', + 'page_latest' + ) + ); + + while ( $page = $pages->fetchObject() ) { + $title = Title::newFromID( $page->page_id ); + ApprovedRevs::setApprovedRevID( $title, $page->page_latest ); + $this->output( "\n" . wfTimestamp( TS_DB ) . ' Page ' . $title->getFullText() . ' now has ' . $page->page_latest . ' as approved revision.' ); + } + + + $this->output( "\n Finished setting all current revisions to approved. \n" ); + } + +} + +$maintClass = "ApproveRevisions"; +require_once( DO_MAINTENANCE ); \ No newline at end of file Deleted: trunk/extensions/ApprovedRevs/maintenance/approveRevisions.php === --- trunk/extensions/ApprovedRevs/maintenance/approveRevisions.php 2010-07-01 23:50:34 UTC (rev 68858) +++ trunk/extensions/ApprovedRevs/maintenance/approveRevisions.php 2010-07-01 23:51:38 UTC (rev 68859) @@ -1,63 +0,0 @@ -http://www.gnu.org/copyleft/gpl.html - * - * @author Jeroen De Dauw - * @ingroup Maintenance - */ - -require_once( dirname( __FILE__ ) . '/../../maintenance/Maintenance.php' ); - -class ApproveRevisions extends Maintenance { - - public function __construct() { - parent::__construct(); - - $this->mDescription = "Approve all current revisions"; - } - - public function execute() { - - $dbr = wfGetDB( DB_SLAVE ); - - $pages = $dbr->select( - 'page', - array( - 'page_id', - 'page_latest' - ) - ); - - while ( $page = $pages->fetchObject() ) { - $title = Title::newFromID( $page->page_id ); - ApprovedRevs::setApprovedRevID( $title, $page->page_latest ); - $this->output( "\n" . wfTimestamp( TS_DB ) . ' Page ' . $title->getFullText() . ' now has ' . $page->page_latest . ' as approved revision.' ); - } - - - $this->output( "\n Finished setting all current revisions to approved. \n" ); - } - -} - -$maintClass = "ApproveRevisions"; -require_once( DO_MAINTENANCE ); \ No newline at end of file ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68858] trunk/extensions/ApprovedRevs/ApprovedRevs_body.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68858 Revision: 68858 Author: yaron Date: 2010-07-01 23:50:34 + (Thu, 01 Jul 2010) Log Message: --- Added NS_MEDIAWIKI to set of unsupported namespaces Modified Paths: -- trunk/extensions/ApprovedRevs/ApprovedRevs_body.php Modified: trunk/extensions/ApprovedRevs/ApprovedRevs_body.php === --- trunk/extensions/ApprovedRevs/ApprovedRevs_body.php 2010-07-01 23:09:48 UTC (rev 68857) +++ trunk/extensions/ApprovedRevs/ApprovedRevs_body.php 2010-07-01 23:50:34 UTC (rev 68858) @@ -50,6 +50,7 @@ $unsupported_namespaces = $egApprovedRevsUnsupportedNamespaces; $unsupported_namespaces[] = NS_FILE; $unsupported_namespaces[] = NS_CATEGORY; + $unsupported_namespaces[] = NS_MEDIAWIKI; return( in_array( $title->getNamespace(), $unsupported_namespaces ) ); } @@ -129,4 +130,4 @@ wfRunHooks( 'ApprovedRevsRevisionUnapproved', array( $parser, $title ) ); } -} \ No newline at end of file +} ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68857] trunk/extensions/LiquidThreads
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68857 Revision: 68857 Author: werdna Date: 2010-07-01 23:09:48 + (Thu, 01 Jul 2010) Log Message: --- LiquidThreads: Fix duplication of "preview" when responding to top-level threads Modified Paths: -- trunk/extensions/LiquidThreads/classes/View.php trunk/extensions/LiquidThreads/lqt.js Modified: trunk/extensions/LiquidThreads/classes/View.php === --- trunk/extensions/LiquidThreads/classes/View.php 2010-07-01 21:58:12 UTC (rev 68856) +++ trunk/extensions/LiquidThreads/classes/View.php 2010-07-01 23:09:48 UTC (rev 68857) @@ -1977,9 +1977,12 @@ $replyInterruption = $levelNum < $totalInLevel; if ( ( $hasSubthreads && $showThreads ) ) { + // If the thread has subthreads, and we want to show them, we should do so. $this->showThreadReplies( $thread, $startAt, $maxCount, $showThreads, $cascadeOptions, $replyInterruption ); } elseif ( $hasSubthreads && !$showThreads ) { + // If the thread has subthreads, but we don't want to show them, then + // show the reply form if necessary, and add the "Show X replies" link. if ( $replyTo ) { $this->showReplyForm( $thread ); } @@ -1994,6 +1997,8 @@ Xml::tags( 'div', array( 'class' => 'lqt-post-sep' ), ' ' ) ); } } elseif ( $levelNum < $totalInLevel ) { + // If we have no replies, and we're not at the end of this level, add the post separator + // and a reply box if necessary. $this->output->addHTML( Xml::tags( 'div', array( 'class' => 'lqt-post-sep' ), ' ' ) ); @@ -2016,6 +2021,8 @@ $this->output->addHTML( $finishHTML ); } } elseif ( !$hasSubthreads && $replyTo ) { + // If we have no replies, we're at the end of this level, and we want to reply, + // show the reply box. $class = 'lqt-thread-replies lqt-thread-replies-' . $this->threadNestingLevel; $html = Xml::openElement( 'div', array( 'class' => $class ) ); @@ -2033,17 +2040,18 @@ $this->output->addHTML( $html ); } - if ( $this->threadNestingLevel == 1 ) { - if ( !( $hasSubthreads && $showThreads ) ) { - $this->showReplyBox( $thread ); - $finishDiv = ''; - $finishDiv .= Xml::tags( 'div', array( 'class' => 'lqt-replies-finish' ), - Xml::tags( 'div', array( 'class' => 'lqt-replies-finish-corner' ), ' ' ) ); + // I don't remember why this is here, commenting out. +// if ( $this->threadNestingLevel == 1 ) { +// if ( !( $hasSubthreads && $showThreads && !$replyTo ) ) { +// $this->showReplyBox( $thread ); +// $finishDiv = ''; +// $finishDiv .= Xml::tags( 'div', array( 'class' => 'lqt-replies-finish' ), +// Xml::tags( 'div', array( 'class' => 'lqt-replies-finish-corner' ), ' ' ) ); +// +// $this->output->addHTML( $finishDiv ); +// } +// } - $this->output->addHTML( $finishDiv ); - } - } - $this->output->addHTML( Xml::closeElement( 'div' ) ); $this->threadNestingLevel--; @@ -2052,7 +2060,6 @@ function showReplyBox( $thread ) { // Check if we're actually replying to this thread. if ( $this->methodAppliesToThread( 'reply', $thread ) ) { - // As with above, flush HTML to avoid refactoring EditPage. $this->showReplyForm( $thread ); return; } elseif ( !$thread->canUserReply( $this->user ) ) { Modified: trunk/extensions/LiquidThreads/lqt.js === --- trunk/extensions/LiquidThreads/lqt.js 2010-07-01 21:58:12 UTC (rev 68856) +++ trunk/extensions/LiquidThreads/lqt.js 2010-07-01 23:09:48 UTC (rev 68857) @@ -1634,6 +1634,7 @@ // Save handlers $j('#wpSave').live( 'click', liquidThreads.handleAJAXSave ); $j('#wpTextbox1').live( 'keyup', liquidThreads.onTextboxKeyUp ); + $j('#wpPreview
[MediaWiki-CVS] SVN: [68856] trunk/extensions/SemanticForms/includes/SF_Utils.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68856 Revision: 68856 Author: yaron Date: 2010-07-01 21:58:12 + (Thu, 01 Jul 2010) Log Message: --- Jamey Wood's fix for setting results limit for 'autocomplete on concept' Modified Paths: -- trunk/extensions/SemanticForms/includes/SF_Utils.php Modified: trunk/extensions/SemanticForms/includes/SF_Utils.php === --- trunk/extensions/SemanticForms/includes/SF_Utils.php2010-07-01 21:11:43 UTC (rev 68855) +++ trunk/extensions/SemanticForms/includes/SF_Utils.php2010-07-01 21:58:12 UTC (rev 68856) @@ -325,7 +325,7 @@ $printout = new SMWPrintRequest( SMWPrintRequest::PRINT_THIS, "" ); $desc->addPrintRequest( $printout ); $query = new SMWQuery( $desc ); - $query->setLimit( $sfgMaxAutocompleteValues ); + //$query->setLimit( $sfgMaxAutocompleteValues ); $query_result = $store->getQueryResult( $query ); $pages = array(); while ( $res = $query_result->getNext() ) { @@ -340,6 +340,12 @@ } else { $pages[] = $page_name; } + // return if we've reached the maximum number of + // allowed values + if ( count( $pages ) > $sfgMaxAutocompleteValues ) { + sort( $pages ); + return $pages; + } } sort( $pages ); return $pages; ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68824] trunk/phase3
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68824 Revision: 68824 Author: platonides Date: 2010-07-01 09:48:53 + (Thu, 01 Jul 2010) Log Message: --- (bug 16886) Sister projects box moves down the extract of the first result in IE 7. Modified Paths: -- trunk/phase3/RELEASE-NOTES trunk/phase3/includes/specials/SpecialSearch.php Added Paths: --- trunk/phase3/skins/common/IE70Fixes.css Modified: trunk/phase3/RELEASE-NOTES === --- trunk/phase3/RELEASE-NOTES 2010-07-01 09:22:56 UTC (rev 68823) +++ trunk/phase3/RELEASE-NOTES 2010-07-01 09:48:53 UTC (rev 68824) @@ -250,6 +250,7 @@ * (bug 24089) Logevents causes PHP Notice if leprop=title isn't supplied * (bug 23473) Give description of properties on all modules * (bug 24136) unknownerror when adding new section without summary, but forceditsummary +* (bug 16886) Sister projects box moves down the extract of the first result in IE 7. === Languages updated in 1.17 === Modified: trunk/phase3/includes/specials/SpecialSearch.php === --- trunk/phase3/includes/specials/SpecialSearch.php2010-07-01 09:22:56 UTC (rev 68823) +++ trunk/phase3/includes/specials/SpecialSearch.php2010-07-01 09:48:53 UTC (rev 68824) @@ -368,6 +368,9 @@ $wgOut->setRobotPolicy( 'noindex,nofollow' ); // add javascript specific to special:search $wgOut->addScriptFile( 'search.js' ); + + // Bug #16886: Sister projects box moves down the first extract on IE7 + $wgOut->addStyle( 'common/IE80Fixes.css', 'screen', 'IE 7' ); } /** @@ -608,7 +611,7 @@ } wfProfileOut( __METHOD__ ); - return "{$link} {$redirect} {$section} {$extract}\n" . + return "{$link} {$redirect} {$section} {$extract}\n" . "{$score}{$size} - {$date}{$related}" . "\n"; Added: trunk/phase3/skins/common/IE70Fixes.css === --- trunk/phase3/skins/common/IE70Fixes.css (rev 0) +++ trunk/phase3/skins/common/IE70Fixes.css 2010-07-01 09:48:53 UTC (rev 68824) @@ -0,0 +1,12 @@ +/** + * Fixes sister projects box moving down the extract + * of the first result (bug #16886). + * It only happens when the window is small and + * This changes slightly the layout for big screens + * where there was space for the extracts and the + * sister projects and thus it showed like in any + * other browser. + */ +.searchresult { + display: inline; +} ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68825] trunk/phase3/skins/common/IE70Fixes.css
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68825 Revision: 68825 Author: platonides Date: 2010-07-01 09:52:28 + (Thu, 01 Jul 2010) Log Message: --- Follow up r68824 with eol style Property Changed: trunk/phase3/skins/common/IE70Fixes.css Property changes on: trunk/phase3/skins/common/IE70Fixes.css ___ Added: svn:eol-style + native ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68855] trunk/extensions/PagedTiffHandler/PagedTiffHandler_body.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68855 Revision: 68855 Author: conrad Date: 2010-07-01 21:11:43 + (Thu, 01 Jul 2010) Log Message: --- Fix strict warning on php 5.3 Modified Paths: -- trunk/extensions/PagedTiffHandler/PagedTiffHandler_body.php Modified: trunk/extensions/PagedTiffHandler/PagedTiffHandler_body.php === --- trunk/extensions/PagedTiffHandler/PagedTiffHandler_body.php 2010-07-01 21:08:41 UTC (rev 68854) +++ trunk/extensions/PagedTiffHandler/PagedTiffHandler_body.php 2010-07-01 21:11:43 UTC (rev 68855) @@ -359,7 +359,7 @@ * Get the thumbnail extension and MIME type for a given source MIME type * @return array thumbnail extension and MIME type */ - function getThumbType( $ext, $mime, $params ) { + function getThumbType( $ext, $mime, $params=null ) { if ( $params[ 'lossy' ] == 'lossy' ) { return array( 'jpg', 'image/jpeg' ); } else { ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68854] branches/resourceloader/phase3
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68854 Revision: 68854 Author: tparscal Date: 2010-07-01 21:08:41 + (Thu, 01 Jul 2010) Log Message: --- Added debug mode and component, which right now is just a flag but it's assumed that it's existence means we're in debug mode, so we can make it an object that does cool stuff later if we want. Also made sure that dynamic loads keep the state of the debug argument. Modified Paths: -- branches/resourceloader/phase3/includes/ResourceLoader.php branches/resourceloader/phase3/load.php branches/resourceloader/phase3/resources/core/mw/mw.loader.js branches/resourceloader/phase3/resources/test/index.html Added Paths: --- branches/resourceloader/phase3/resources/core/mw/mw.debug.js branches/resourceloader/phase3/resources/core/mw/mw.log.js Removed Paths: - branches/resourceloader/phase3/resources/core/mw/mw.log.js Modified: branches/resourceloader/phase3/includes/ResourceLoader.php === --- branches/resourceloader/phase3/includes/ResourceLoader.php 2010-07-01 20:51:01 UTC (rev 68853) +++ branches/resourceloader/phase3/includes/ResourceLoader.php 2010-07-01 21:08:41 UTC (rev 68854) @@ -31,10 +31,13 @@ 'mw' => 'resources/core/mw.js', 'mw.config' => 'resources/core/mw/mw.config.js', 'mw.loader' => 'resources/core/mw/mw.loader.js', - 'mw.log' => 'resources/core/mw/mw.log.js', 'mw.msg' => 'resources/core/mw/mw.msg.js', 'mw.util' => 'resources/core/mw/mw.util.js', ); + private static $debugScripts = array( + 'mw.debug' => 'resources/core/mw/mw.debug.js', + 'mw.log' => 'resources/core/mw/mw.log.js', + ); /** * List of modules. * @@ -137,6 +140,16 @@ } $retval .= $this->getLoaderJS(); } + if ( $this->useDebugMode ) { + // TODO: file_get_contents() errors? + // TODO: CACHING! + foreach ( self::$debugScripts as $script ) { + if ( file_exists( $script ) ) { + $retval .= file_get_contents( $script ); + } + } + $retval .= $this->getLoaderJS(); + } /* * Skin::makeGlobalVariablesScript needs to be modified so that we still output the globals for now, but also Modified: branches/resourceloader/phase3/load.php === --- branches/resourceloader/phase3/load.php 2010-07-01 20:51:01 UTC (rev 68853) +++ branches/resourceloader/phase3/load.php 2010-07-01 21:08:41 UTC (rev 68854) @@ -49,8 +49,8 @@ $loader = new ResourceLoader( $wgRequest->getVal( 'lang', 'en' ) ); $loader->setUseJSMin( $wgRequest->getBool( 'jsmin', true ) ); $loader->setUseCSSMin( $wgRequest->getBool( 'cssmin', true ) ); +$loader->setUseCSSJanus( $wgRequest->getVal( 'dir', 'ltr' ) == 'rtl' ); $loader->setUseDebugMode( $wgRequest->getBool( 'debug', false ) ); -$loader->setUseCSSJanus( $wgRequest->getVal( 'dir', 'ltr' ) == 'rtl' ); $moduleParam = $wgRequest->getVal( 'modules' ); $modules = $moduleParam ? explode( '|', $moduleParam ) : array(); foreach ( $modules as $module ) { Added: branches/resourceloader/phase3/resources/core/mw/mw.debug.js === --- branches/resourceloader/phase3/resources/core/mw/mw.debug.js (rev 0) +++ branches/resourceloader/phase3/resources/core/mw/mw.debug.js 2010-07-01 21:08:41 UTC (rev 68854) @@ -0,0 +1,5 @@ +/** + * Debug system + */ + +window.mw.debug = true; \ No newline at end of file Property changes on: branches/resourceloader/phase3/resources/core/mw/mw.debug.js ___ Added: svn:eol-style + native Modified: branches/resourceloader/phase3/resources/core/mw/mw.loader.js === --- branches/resourceloader/phase3/resources/core/mw/mw.loader.js 2010-07-01 20:51:01 UTC (rev 68853) +++ branches/resourceloader/phase3/resources/core/mw/mw.loader.js 2010-07-01 21:08:41 UTC (rev 68854) @@ -135,7 +135,9 @@ // Modules are in the format foo|bar|baz|buz { 'modules': batch.join( '|' ) }, // Pass configuration values through the URL - m
[MediaWiki-CVS] SVN: [68826] trunk/WikiWord/WikiWord/src
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68826 Revision: 68826 Author: daniel Date: 2010-07-01 10:31:44 + (Thu, 01 Jul 2010) Log Message: --- make coherence score more sensitive to frequency: normalize before averaging and use a softer normalization curve Modified Paths: -- trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/disambig/CoherenceDisambiguator.java trunk/WikiWord/WikiWord/src/test/java/de/brightbyte/wikiword/disambig/CoherenceDisambiguatorTest.java Modified: trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/disambig/CoherenceDisambiguator.java === --- trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/disambig/CoherenceDisambiguator.java 2010-07-01 09:52:28 UTC (rev 68825) +++ trunk/WikiWord/WikiWord/src/main/java/de/brightbyte/wikiword/disambig/CoherenceDisambiguator.java 2010-07-01 10:31:44 UTC (rev 68826) @@ -77,7 +77,10 @@ if (pop<0.5) return 0; if (pop<1) pop=1; - double n = 1 - 1/(Math.sqrt(Math.log(pop))+1); //XXX: black voodoo magic ad hoc formula with no deeper meaing. + //XXX: black voodoo magic ad hoc formula with no deeper meaing. + //double n = 1 - 1/(Math.log(pop)+1); //normalized log scale + //double n = 1 - 1/(Math.sqrt(Math.log(pop))+1); //dampened normalized log scale + double n =1 - (0.5/Math.sqrt((pop+200)/200)); //nice and smooth, but has magic params that may depend on the wiki return n; } }; @@ -436,7 +439,8 @@ LabeledVector sum = ConceptFeatures.newIntFeaturVector( concepts.size() * 200 ); //XXX: magic number Map> disambigFeatures = new HashMap>(); - double sim = 0, pop = 0, weight = 0; + double sim = 0, pop = 0, weight = 0, popf = 0, simf = 0; + int i=0, j=0; for (Map.Entry ea: concepts.entrySet()) { C a = ea.getValue(); @@ -496,6 +500,8 @@ d = doubleSanity(d, "normal similarity score for "+a+" / "+b, "check similarityMeasure!", 0, 0.1, 1, 0.1); sim += d; + simf += similarityNormalizer.apply(d); + simCount ++; } @@ -508,7 +514,9 @@ p = weightCombiner.apply(p, w); - pop += p; //XXX: keep raw and processed pop + pop += p; + popf += popularityNormalizer.apply(p); + weight += w; } @@ -523,14 +531,15 @@ sim = n == 0 ? 0 : sim / n; //scale pop = c == 0 ? 0 : pop / c; //scale + + simf = n == 0 ? 0 : simf / n; //scale + popf = c == 0 ? 0 : popf / c; //scale + weight = c == 0 ? 0 : weight / c; //scale pop = doubleSanity(pop, "normal popularity", "check popularityMeasure!", 0, 0.1, Double.MAX_VALUE, 0); sim = doubleSanity(sim, "normal average simility", "ooops!", 0, 0.1, 1, 0.1); - double popf = popularityNormalizer.apply(pop); - double simf = similarityNormalizer.apply(sim); - popf = doubleSanity(popf, "normal popularity", "check popularityNormalizer!", 0, 0.1, 1, 0.1); simf = doubleSanity(simf, "normal similarity", "check similarityNormalizer!", 0, 0.1, 1, 0.1); Modified: trunk/WikiWord/WikiWord/src/test/java/de/brightbyte/wikiword/disambig/CoherenceDisambiguatorTest.java === --- trunk/WikiWord/WikiWord/src/test/java/de/brightbyte/wikiword/disambig/CoherenceDisambiguatorTest.java 2010-07-01 09:52:28 UTC (rev 68825) +++ trunk/WikiWord/WikiWord/src/test/java/de/brightbyte/wikiword/disambig/CoherenceDisambiguatorTest.java 2010-07-01 10:31:44 UTC (rev 68826) @@ -6,10 +6,13 @@ import java.util.List; import java.util.Map; +import de.brightbyte.data.LabeledMatrix; +import de.brightbyte.data.MapLabeledMatrix; import de.brightbyte.data.Pair; import de.brightbyte.io.ConsoleIO; import de.brightbyte.io.Output; import de.brightbyte.util.PersistenceException; +import de.brightbyte.wikiword.disambig.CoherenceDisambiguator.CoherenceDisambiguation; import de.brightbyte.wikiword.disambig.Disambiguator.Interpretation; import de.brightbyte.wikiword.disambig.Disambiguator.Disambiguation; import de.brightbyte.wik
[MediaWiki-CVS] SVN: [68852] trunk/phase3/includes
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68852 Revision: 68852 Author: ialex Date: 2010-07-01 20:45:21 + (Thu, 01 Jul 2010) Log Message: --- Fixed some doxygen warnings Modified Paths: -- trunk/phase3/includes/Preferences.php trunk/phase3/includes/Profiler.php Modified: trunk/phase3/includes/Preferences.php === --- trunk/phase3/includes/Preferences.php 2010-07-01 20:35:14 UTC (rev 68851) +++ trunk/phase3/includes/Preferences.php 2010-07-01 20:45:21 UTC (rev 68852) @@ -996,8 +996,8 @@ } /** -* @param object $user The user object -* @return array Text/links to display as key; $skinkey as value +* @param $user The User object +* @return Array: text/links to display as key; $skinkey as value */ static function generateSkinOptions( $user ) { global $wgDefaultSkin, $wgLang, $wgAllowUserCss, $wgAllowUserJs; Modified: trunk/phase3/includes/Profiler.php === --- trunk/phase3/includes/Profiler.php 2010-07-01 20:35:14 UTC (rev 68851) +++ trunk/phase3/includes/Profiler.php 2010-07-01 20:45:21 UTC (rev 68852) @@ -12,7 +12,7 @@ /** * Begin profiling of a function - * @param $functionname name of the function we will profile + * @param $functionname String: name of the function we will profile */ function wfProfileIn( $functionname ) { global $wgProfiler; @@ -21,7 +21,7 @@ /** * Stop profiling of a function - * @param $functionname name of the function we have profiled + * @param $functionname String: name of the function we have profiled */ function wfProfileOut( $functionname = 'missing' ) { global $wgProfiler; @@ -76,7 +76,8 @@ /** * Called by wfProfieIn() -* @param $functionname string +* +* @param $functionname String */ function profileIn( $functionname ) { global $wgDebugFunctionEntry, $wgProfiling; @@ -90,7 +91,8 @@ /** * Called by wfProfieOut() -* @param $functionname string +* +* @param $functionname String */ function profileOut($functionname) { global $wgDebugFunctionEntry, $wgProfiling; @@ -142,6 +144,7 @@ /** * Mark this call as templated or not +* * @param $t Boolean */ function setTemplated( $t ) { @@ -149,7 +152,7 @@ } /** -* called by wfGetProfilingOutput() +* Called by wfGetProfilingOutput() */ function getOutput() { global $wgDebugFunctionEntry, $wgProfileCallTree; @@ -173,7 +176,7 @@ } /** -* returns a tree of function call instead of a list of functions +* Returns a tree of function call instead of a list of functions */ function getCallTree() { return implode( '', array_map( array( &$this, 'getCallTreeLine' ), $this->remapCallTree( $this->mStack ) ) ); @@ -365,9 +368,10 @@ /** * Log a function into the database. * -* @param $name string: function name -* @param $timeSum float -* @param $eventCount int: number of times that function was called +* @param $name String: function name +* @param $timeSum Float +* @param $eventCount Integer: number of times that function was called +* @param $memorySum Integer: memory used by the function */ static function logToDB( $name, $timeSum, $eventCount, $memorySum ){ # Do not log anything if database is readonly (bug 5375) @@ -429,7 +433,8 @@ /** * Get function caller -* @param $level int +* +* @param $level Integer */ static function getCaller( $level ) { $backtrace = wfDebugBacktrace(); @@ -447,7 +452,8 @@ /** * Add an entry in the debug log file -* @param $s string to output +* +* @param $s String to output */ function debug( $s ) { if( function_exists( 'wfDebug' ) ) { ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68851] trunk/extensions/MultiUpload/MultiUpload.body.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68851 Revision: 68851 Author: ialex Date: 2010-07-01 20:35:14 + (Thu, 01 Jul 2010) Log Message: --- Removed unused global Modified Paths: -- trunk/extensions/MultiUpload/MultiUpload.body.php Modified: trunk/extensions/MultiUpload/MultiUpload.body.php === --- trunk/extensions/MultiUpload/MultiUpload.body.php 2010-07-01 20:22:36 UTC (rev 68850) +++ trunk/extensions/MultiUpload/MultiUpload.body.php 2010-07-01 20:35:14 UTC (rev 68851) @@ -308,7 +308,7 @@ } if ( $licenseshtml != '' ) { - global $wgAjaxLicensePreview, $wgJsMimeType; + global $wgAjaxLicensePreview; $wgOut->addScriptFile( 'upload.js' ); // This is one nasty hack...but necessary to make upload.js not bitch if the user actually touches the "Licensing" dropdown menu instead of just admiring it from a distance. $wgOut->addInlineScript( 'var wgAjaxLicensePreview = "'.$wgAjaxLicensePreview.'";' ); ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68827] trunk/extensions/AuthorProtect/AuthorProtect.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68827 Revision: 68827 Author: nikerabbit Date: 2010-07-01 11:04:00 + (Thu, 01 Jul 2010) Log Message: --- Code cleanup, i18n fixes and fixmes Modified Paths: -- trunk/extensions/AuthorProtect/AuthorProtect.php Modified: trunk/extensions/AuthorProtect/AuthorProtect.php === --- trunk/extensions/AuthorProtect/AuthorProtect.php2010-07-01 10:31:44 UTC (rev 68826) +++ trunk/extensions/AuthorProtect/AuthorProtect.php2010-07-01 11:04:00 UTC (rev 68827) @@ -99,7 +99,6 @@ function efAuthorProtectForm( $action, $article ) { global $wgTitle, $wgAuthorProtectDoProtect; if ( $action == 'authorprotect' ) { - wfLoadExtensionMessages( 'AuthorProtect' ); global $wgOut, $wgUser, $wgRequest, $wgRestrictionTypes; if ( $wgUser->isAllowed( 'authorprotect' ) ) { if ( userIsAuthor() ) { @@ -109,7 +108,7 @@ } else { if ( !$wgUser->matchEditToken( $wgRequest->getText( 'wpToken' ) ) ) { $wgOut->setPageTitle( wfMsg( 'errorpagetitle' ) ); - $wgOut->addWikiText( wfMsg( 'sessionfailure' ) ); + $wgOut->addWikiMsg( 'sessionfailure' ); return false; } $restrictions = array(); @@ -148,14 +147,14 @@ ); efAuthorProtectUnassignProtect(); if ( $success ) { - $wgOut->addWikiText( wfMsg( 'authorprotect-success' ) ); + $wgOut->addWikiMsg( 'authorprotect-success' ); } else { - $wgOut->addWikiText( wfMsg( 'authorprotect-failure' ) ); + $wgOut->addWikiMsg( 'authorprotect-failure' ); } } } else { $wgOut->setPageTitle( wfMsg( 'errorpagetitle' ) ); - $wgOut->addWikiText( wfMsg( 'authorprotect-notauthor' ) ); + $wgOut->addWikiMsg( 'authorprotect-notauthor' ); } } else { $wgOut->permissionRequired( 'authorprotect' ); @@ -168,27 +167,30 @@ function efAuthorProtectMakeProtectForm() { global $wgRestrictionTypes, $wgTitle, $wgUser; $token = $wgUser->editToken(); + // FIXME: raw html messages $form = Xml::openElement( 'p' ) . wfMsg( 'authorprotect-intro' ) . Xml::closeElement( 'p' ); $form .= Xml::openElement( 'form', array( 'method' => 'post', 'action' => $wgTitle->getLocalUrl( 'action=authorprotect' ) ) ); + + $br = Html::element( 'br' ); + foreach ( $wgRestrictionTypes as $type ) { $rest = $wgTitle->getRestrictions( $type ); if ( $rest !== array() ) { if ( !$wgUser->isAllowed( $rest[0] ) && !in_array( 'author', $rest ) ) continue; // it's protected at a level higher than them, so don't let them change it so they can now mess with stuff } - $checked = in_array( 'author', $rest ); - $array = array( 'type' => 'checkbox', 'name' => 'check-' . $type, 'value' => $type ); - if ( $checked ) - $array = array_merge( $array, array( 'checked' => 'checked' ) ); - $form .= Xml::element( 'input', $array ); - $form .= ' ' . wfMsg( 'authorprotect-' . $type ) . Xml::element( 'br' ); + + $checked = in_array( 'author', $rest ); + $form .= Xml::checkLabel( wfMsg( "authorprotect-$type" ), "check-$type", "check-$type", $checked ) . $br; } - $form .= Xml::element( 'br' ) . Xml::element( 'label', array( 'for' => 'wpExpiryTime' ), wfMsg( 'authorprotect-expiry' ) ) . ' '; - $form .= Xml::element( 'input', array( 'type' => 'text', 'name' => 'wpExpiryTime' ) ) . Xml::element( 'br' ); - $form .= Xml::element( 'br' ) . Xml::element( 'label', array( 'for' => 'wpReason' ), wfMsg( 'authorprotect-reason' ) ) . ' '; + + // FIXME: use Xml::inputLabel + $form .= $br . Xml::element( 'label', array( 'for' => 'wpExpiryTime' ), wfMsg( 'authorprotect-expiry' ) ) . ' '; + $form .= Xml::element( 'input', array( 'type' => 'text', 'name' => 'wpExpiryTime' ) ) . $br; + $form .= $br . Xml::element(
[MediaWiki-CVS] SVN: [68850] branches/wmf/1.16wmf4/extensions/CodeReview
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68850 Revision: 68850 Author: catrope Date: 2010-07-01 20:22:36 + (Thu, 01 Jul 2010) Log Message: --- 1.16wmf4: Merge r63277, r63278 (CodeReview auto-deferral by regex) from trunk per Chad's request Modified Paths: -- branches/wmf/1.16wmf4/extensions/CodeReview/CodeReview.php branches/wmf/1.16wmf4/extensions/CodeReview/backend/CodeRevision.php Property Changed: branches/wmf/1.16wmf4/extensions/CodeReview/ Property changes on: branches/wmf/1.16wmf4/extensions/CodeReview ___ Modified: svn:mergeinfo - /branches/wmf-deployment/extensions/CodeReview:60970 /trunk/extensions/CodeReview:67212 /trunk/phase3/extensions/CodeReview:63545-63546,63549,63643,63764,63897-63901,64113,64509,65387,65391,6,65590,65650,65816 + /branches/wmf-deployment/extensions/CodeReview:60970 /trunk/extensions/CodeReview:63277-63278,67212 /trunk/phase3/extensions/CodeReview:63545-63546,63549,63643,63764,63897-63901,64113,64509,65387,65391,6,65590,65650,65816 Modified: branches/wmf/1.16wmf4/extensions/CodeReview/CodeReview.php === --- branches/wmf/1.16wmf4/extensions/CodeReview/CodeReview.php 2010-07-01 19:57:26 UTC (rev 68849) +++ branches/wmf/1.16wmf4/extensions/CodeReview/CodeReview.php 2010-07-01 20:22:36 UTC (rev 68850) @@ -151,6 +151,13 @@ */ $wgCodeReviewMaxDiffSize = 50; +/** + * Any base paths matching regular expressions in this array will have their + * default status set to deferred instead of new. Helpful if you've got a part + * of the repository you don't care about. + */ +$wgCodeReviewDeferredPaths = array(); + # Schema changes $wgHooks['LoadExtensionSchemaUpdates'][] = 'efCodeReviewSchemaUpdates'; Modified: branches/wmf/1.16wmf4/extensions/CodeReview/backend/CodeRevision.php === --- branches/wmf/1.16wmf4/extensions/CodeReview/backend/CodeRevision.php 2010-07-01 19:57:26 UTC (rev 68849) +++ branches/wmf/1.16wmf4/extensions/CodeReview/backend/CodeRevision.php 2010-07-01 20:22:36 UTC (rev 68850) @@ -41,6 +41,15 @@ } } $rev->mCommonPath = $common; + + // Check for ignored paths + global $wgCodeReviewDeferredPaths; + foreach( $wgCodeReviewDeferredPaths as $defer ) { + if( preg_match( $defer, $rev->mCommonPath ) ) { + $rev->mStatus = 'deferred'; + break; + } + } return $rev; } ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68849] trunk/phase3/skins/common/upload.js
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68849 Revision: 68849 Author: hartman Date: 2010-07-01 19:57:26 + (Thu, 01 Jul 2010) Log Message: --- Make sure we use the right variable. Follow up r68848. Modified Paths: -- trunk/phase3/skins/common/upload.js Modified: trunk/phase3/skins/common/upload.js === --- trunk/phase3/skins/common/upload.js 2010-07-01 19:55:04 UTC (rev 68848) +++ trunk/phase3/skins/common/upload.js 2010-07-01 19:57:26 UTC (rev 68849) @@ -242,7 +242,7 @@ // Clear the filename if it does not have a valid extension. // URLs are less likely to have a useful extension, so don't include them in the // extension check. - if( $wgStrictFileExtensions && wgFileExtensions && id != 'wpUploadFileURL' ) { + if( wgStrictFileExtensions && wgFileExtensions && id != 'wpUploadFileURL' ) { var found = false; if( fname.lastIndexOf( '.' ) != -1 ) { var ext = fname.substr( fname.lastIndexOf( '.' ) + 1 ); ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68848] trunk/phase3
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68848 Revision: 68848 Author: hartman Date: 2010-07-01 19:55:04 + (Thu, 01 Jul 2010) Log Message: --- (bug 24022) Don't check extensions of files in uploadpage script when $wgStrictFileExtensions == false Modified Paths: -- trunk/phase3/RELEASE-NOTES trunk/phase3/includes/specials/SpecialUpload.php trunk/phase3/skins/common/upload.js Modified: trunk/phase3/RELEASE-NOTES === --- trunk/phase3/RELEASE-NOTES 2010-07-01 19:37:00 UTC (rev 68847) +++ trunk/phase3/RELEASE-NOTES 2010-07-01 19:55:04 UTC (rev 68848) @@ -221,6 +221,7 @@ * (bug 23642) Recognize mime types of MS OpenXML documents. * (bug 22784) Normalise underscores and spaces in autocomments. * (bug 19910) Headings of the form ===+\s+ are now displayed as valid headings +* (bug 24022) Only check file extensions on the uploadpage when needed. === API changes in 1.17 === * (bug 22738) Allow filtering by action type on query=logevent. Modified: trunk/phase3/includes/specials/SpecialUpload.php === --- trunk/phase3/includes/specials/SpecialUpload.php2010-07-01 19:37:00 UTC (rev 68847) +++ trunk/phase3/includes/specials/SpecialUpload.php2010-07-01 19:55:04 UTC (rev 68848) @@ -1044,7 +1044,7 @@ * Add upload JS to $wgOut */ protected function addUploadJS() { - global $wgUseAjax, $wgAjaxUploadDestCheck, $wgAjaxLicensePreview, $wgEnableAPI; + global $wgUseAjax, $wgAjaxUploadDestCheck, $wgAjaxLicensePreview, $wgEnableAPI, $wgStrictFileExtensions; global $wgOut; $useAjaxDestCheck = $wgUseAjax && $wgAjaxUploadDestCheck; @@ -1058,6 +1058,7 @@ // the wpDestFile textbox $this->mDestFile === '', 'wgUploadSourceIds' => $this->mSourceIds, + 'wgStrictFileExtensions' => $wgStrictFileExtensions, ); $wgOut->addScript( Skin::makeVariablesScript( $scriptVars ) ); Modified: trunk/phase3/skins/common/upload.js === --- trunk/phase3/skins/common/upload.js 2010-07-01 19:37:00 UTC (rev 68847) +++ trunk/phase3/skins/common/upload.js 2010-07-01 19:55:04 UTC (rev 68848) @@ -242,7 +242,7 @@ // Clear the filename if it does not have a valid extension. // URLs are less likely to have a useful extension, so don't include them in the // extension check. - if( wgFileExtensions && id != 'wpUploadFileURL' ) { + if( $wgStrictFileExtensions && wgFileExtensions && id != 'wpUploadFileURL' ) { var found = false; if( fname.lastIndexOf( '.' ) != -1 ) { var ext = fname.substr( fname.lastIndexOf( '.' ) + 1 ); ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68829] trunk/extensions/SemanticMaps
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68829 Revision: 68829 Author: jeroendedauw Date: 2010-07-01 11:42:52 + (Thu, 01 Jul 2010) Log Message: --- Patch to enable KML for google maps submitted by 67.170.217.247 Modified Paths: -- trunk/extensions/SemanticMaps/SemanticMaps.php trunk/extensions/SemanticMaps/Services/GoogleMaps/SM_GoogleMapsFormInput.php trunk/extensions/SemanticMaps/Services/GoogleMaps/SM_GoogleMapsQP.php Modified: trunk/extensions/SemanticMaps/SemanticMaps.php === --- trunk/extensions/SemanticMaps/SemanticMaps.php 2010-07-01 11:42:44 UTC (rev 68828) +++ trunk/extensions/SemanticMaps/SemanticMaps.php 2010-07-01 11:42:52 UTC (rev 68829) @@ -35,7 +35,7 @@ // Only initialize the extension when all dependencies are present. if ( defined( 'Maps_VERSION' ) && defined( 'SMW_VERSION' ) ) { - define( 'SM_VERSION', '0.6.4 a3' ); + define( 'SM_VERSION', '0.6.4 a4' ); $smgScriptPath = ( isset( $wgExtensionAssetsPath ) && $wgExtensionAssetsPath ? $wgExtensionAssetsPath : $wgScriptPath . '/extensions' ) . '/SemanticMaps'; $smgDir = dirname( __FILE__ ) . '/'; Modified: trunk/extensions/SemanticMaps/Services/GoogleMaps/SM_GoogleMapsFormInput.php === --- trunk/extensions/SemanticMaps/Services/GoogleMaps/SM_GoogleMapsFormInput.php 2010-07-01 11:42:44 UTC (rev 68828) +++ trunk/extensions/SemanticMaps/Services/GoogleMaps/SM_GoogleMapsFormInput.php 2010-07-01 11:42:52 UTC (rev 68829) @@ -98,7 +98,8 @@ type: $this->type, types: [$this->types], controls: [$this->controls], - scrollWheelZoom: $this->autozoom + scrollWheelZoom: $this->autozoom, + kml: '$this->kml' }, {$this->markerCoords['lat']}, {$this->markerCoords['lon']} Modified: trunk/extensions/SemanticMaps/Services/GoogleMaps/SM_GoogleMapsQP.php === --- trunk/extensions/SemanticMaps/Services/GoogleMaps/SM_GoogleMapsQP.php 2010-07-01 11:42:44 UTC (rev 68828) +++ trunk/extensions/SemanticMaps/Services/GoogleMaps/SM_GoogleMapsQP.php 2010-07-01 11:42:52 UTC (rev 68829) @@ -89,7 +89,8 @@ type: $this->type, types: [$this->types], controls: [$this->controls], - scrollWheelZoom: $this->autozoom + scrollWheelZoom: $this->autozoom, + kml: '$this->kml' }, [$markersString] ); ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68846] trunk/phase3
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68846 Revision: 68846 Author: conrad Date: 2010-07-01 19:11:22 + (Thu, 01 Jul 2010) Log Message: --- texvc +\bcancel and \xcancel to make full use of the cancel package Modified Paths: -- trunk/phase3/RELEASE-NOTES trunk/phase3/math/texutil.ml Modified: trunk/phase3/RELEASE-NOTES === --- trunk/phase3/RELEASE-NOTES 2010-07-01 18:37:01 UTC (rev 68845) +++ trunk/phase3/RELEASE-NOTES 2010-07-01 19:11:22 UTC (rev 68846) @@ -97,6 +97,7 @@ * (bug 8507) Group file links by namespace:title on image pages * Stop emitting named entities, so we can use while still being well-formed XML +* texvc now supports \bcancel and \xcancel in addition to \cancel and \cancelto === Bug fixes in 1.17 === * (bug 17560) Half-broken deletion moved image files to deletion archive Modified: trunk/phase3/math/texutil.ml === --- trunk/phase3/math/texutil.ml2010-07-01 18:37:01 UTC (rev 68845) +++ trunk/phase3/math/texutil.ml2010-07-01 19:11:22 UTC (rev 68846) @@ -512,6 +512,8 @@ | "\\over" -> FUN_INFIXh ("\\over ", fun num den -> Html.html_render num, "", Html.html_render den) | "\\sqrt" -> FUN_AR1 "\\sqrt " | "\\cancel" -> FUN_AR1 "\\cancel " +| "\\bcancel" -> FUN_AR1 "\\bcancel " +| "\\xcancel" -> FUN_AR1 "\\xcancel " | "\\cancelto" -> FUN_AR2 "\\cancelto " | "\\pmod" -> FUN_AR1hl ("\\pmod ", ("(mod ", ")")) | "\\bmod" -> FUN_AR1hl ("\\bmod ", ("mod ", "")) ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68845] trunk/extensions/UsabilityInitiative/Vector
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68845 Revision: 68845 Author: catrope Date: 2010-07-01 18:37:01 + (Thu, 01 Jul 2010) Log Message: --- UsabilityInitiative: (bug 24216) Fix regression from r68229 causing the second attempt to leave the page not to trigger EditWarning. Solved in a kind of hackish way but it works. Modified Paths: -- trunk/extensions/UsabilityInitiative/Vector/Modules/EditWarning/EditWarning.js trunk/extensions/UsabilityInitiative/Vector/Vector.combined.js trunk/extensions/UsabilityInitiative/Vector/Vector.combined.min.js trunk/extensions/UsabilityInitiative/Vector/Vector.hooks.php Modified: trunk/extensions/UsabilityInitiative/Vector/Modules/EditWarning/EditWarning.js === --- trunk/extensions/UsabilityInitiative/Vector/Modules/EditWarning/EditWarning.js 2010-07-01 18:11:42 UTC (rev 68844) +++ trunk/extensions/UsabilityInitiative/Vector/Modules/EditWarning/EditWarning.js 2010-07-01 18:37:01 UTC (rev 68845) @@ -14,6 +14,7 @@ var ourWindowOnBeforeUnload = function() { var fallbackResult = undefined; var retval = undefined; + var thisFunc = arguments.callee; // Check if someone already set on onbeforeunload hook if ( fallbackWindowOnBeforeUnload ) { // Get the result of their onbeforeunload hook @@ -39,6 +40,10 @@ // Unset the onbeforeunload handler so we don't break page caching in Firefox window.onbeforeunload = null; if ( retval !== undefined ) { + // ...but if the user chooses not to leave the page, we need to rebind it + setTimeout( function() { + window.onbeforeunload = thisFunc; + } ); return retval; } }; Modified: trunk/extensions/UsabilityInitiative/Vector/Vector.combined.js === --- trunk/extensions/UsabilityInitiative/Vector/Vector.combined.js 2010-07-01 18:11:42 UTC (rev 68844) +++ trunk/extensions/UsabilityInitiative/Vector/Vector.combined.js 2010-07-01 18:37:01 UTC (rev 68845) @@ -312,6 +312,7 @@ var ourWindowOnBeforeUnload = function() { var fallbackResult = undefined; var retval = undefined; + var thisFunc = arguments.callee; // Check if someone already set on onbeforeunload hook if ( fallbackWindowOnBeforeUnload ) { // Get the result of their onbeforeunload hook @@ -337,6 +338,10 @@ // Unset the onbeforeunload handler so we don't break page caching in Firefox window.onbeforeunload = null; if ( retval !== undefined ) { + // ...but if the user chooses not to leave the page, we need to rebind it + setTimeout( function() { + window.onbeforeunload = thisFunc; + } ); return retval; } }; Modified: trunk/extensions/UsabilityInitiative/Vector/Vector.combined.min.js === --- trunk/extensions/UsabilityInitiative/Vector/Vector.combined.min.js 2010-07-01 18:11:42 UTC (rev 68844) +++ trunk/extensions/UsabilityInitiative/Vector/Vector.combined.min.js 2010-07-01 18:37:01 UTC (rev 68845) @@ -15,9 +15,9 @@ var rtl=$j('body').is('.rtl');$j.collapsibleTabs.moveToCollapsed=function(ele){var $moving=$j(ele);$j.collapsibleTabs.getSettings($j($j.collapsibleTabs.getSettings($moving).expandedContainer)).shifting=true;var data=$j.collapsibleTabs.getSettings($moving);var target=data.collapsedContainer;$moving.css("position","relative").css((rtl?'left':'right'),0).animate({width:'1px'},"normal",function(){$j(this).hide();$j('').insertAfter(this);$j(this).remove().prependTo(target).data('collapsibleTabsSettings',data);$j(this).attr('style','display:list-item;');$j.collapsibleTabs.getSettings($j($j.collapsibleTabs.getSettings($j(ele)).expandedContainer)).shifting=false;$j.collapsibleTabs.handleResize();});};$j.collapsibleTabs.moveToExpanded=function(ele){var $moving=$j(ele);$j.collapsibleTabs.getSettings($j($j.collapsibleTabs.getSettings($moving).expandedContainer)).shifting=true;var data=$j.collapsibleTabs.getSettings($moving);var $target=$j(data.expandedContainer).find('span.placeholder:first');var expandedWidth=data.expandedWidth;$moving.css("position","relative").css((rtl?'right':'left'),0).css('width','1px');$target.replaceWith($moving.remove().css('width','1px').data('collapsibleTabsSettings',data).animate({width:expandedWidth+"px"},"normal",function(){$j(this).attr('style','display:block;');$j.collapsibleT
[MediaWiki-CVS] SVN: [68844] branches/wmf/1.16wmf4/extensions/StrategyWiki
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68844 Revision: 68844 Author: werdna Date: 2010-07-01 18:11:42 + (Thu, 01 Jul 2010) Log Message: --- Merge r68843 Modified Paths: -- branches/wmf/1.16wmf4/extensions/StrategyWiki/ActiveStrategy/ParserFunctions.php Property Changed: branches/wmf/1.16wmf4/extensions/StrategyWiki/ Property changes on: branches/wmf/1.16wmf4/extensions/StrategyWiki ___ Modified: svn:mergeinfo - /branches/wmf-deployment/extensions/StrategyWiki:60970 /trunk/extensions/StrategyWiki:66058-67532,67775,67778,67939-67940,67942,68196,68198,68200,68202,68204,68206,68488,68672 /trunk/phase3/extensions/StrategyWiki:63545-63546,63549,63643,63764,63897-63901,64113,64509,65387,65391,6,65590,65650,65816 + /branches/wmf-deployment/extensions/StrategyWiki:60970 /trunk/extensions/StrategyWiki:66058-67532,67775,67778,67939-67940,67942,68196,68198,68200,68202,68204,68206,68488,68672,68843 /trunk/phase3/extensions/StrategyWiki:63545-63546,63549,63643,63764,63897-63901,64113,64509,65387,65391,6,65590,65650,65816 Modified: branches/wmf/1.16wmf4/extensions/StrategyWiki/ActiveStrategy/ParserFunctions.php === --- branches/wmf/1.16wmf4/extensions/StrategyWiki/ActiveStrategy/ParserFunctions.php 2010-07-01 18:09:08 UTC (rev 68843) +++ branches/wmf/1.16wmf4/extensions/StrategyWiki/ActiveStrategy/ParserFunctions.php 2010-07-01 18:11:42 UTC (rev 68844) @@ -2,6 +2,7 @@ class ActiveStrategyPF { static function activityTag( $str, $args, $parser ) { + $parser->getOutput()->updateCacheExpiry( 900 ); return ActiveStrategy::getOutput( $args ); } ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68843] trunk/extensions/StrategyWiki/ActiveStrategy/ParserFunctions. php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68843 Revision: 68843 Author: werdna Date: 2010-07-01 18:09:08 + (Thu, 01 Jul 2010) Log Message: --- Set cache expiry for ActiveStrategy to 900 s (15min) Modified Paths: -- trunk/extensions/StrategyWiki/ActiveStrategy/ParserFunctions.php Modified: trunk/extensions/StrategyWiki/ActiveStrategy/ParserFunctions.php === --- trunk/extensions/StrategyWiki/ActiveStrategy/ParserFunctions.php 2010-07-01 18:04:41 UTC (rev 68842) +++ trunk/extensions/StrategyWiki/ActiveStrategy/ParserFunctions.php 2010-07-01 18:09:08 UTC (rev 68843) @@ -2,6 +2,7 @@ class ActiveStrategyPF { static function activityTag( $str, $args, $parser ) { + $parser->getOutput()->updateCacheExpiry( 900 ); return ActiveStrategy::getOutput( $args ); } ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68841] trunk/extensions/UsabilityInitiative
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68841 Revision: 68841 Author: catrope Date: 2010-07-01 17:53:40 + (Thu, 01 Jul 2010) Log Message: --- UsabilityInitiative: (bug 24208) "undefinedundefinedundefined" shown in special characters. Caused by a combination of user scripts adding stuff to Array.prototype and a bad for loop Modified Paths: -- trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php trunk/extensions/UsabilityInitiative/js/plugins/jquery.wikiEditor.toolbar.js trunk/extensions/UsabilityInitiative/js/plugins.combined.js trunk/extensions/UsabilityInitiative/js/plugins.combined.min.js Modified: trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php === --- trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php 2010-07-01 17:52:33 UTC (rev 68840) +++ trunk/extensions/UsabilityInitiative/UsabilityInitiative.hooks.php 2010-07-01 17:53:40 UTC (rev 68841) @@ -69,7 +69,7 @@ array( 'src' => 'js/plugins/jquery.textSelection.js', 'version' => 36 ), array( 'src' => 'js/plugins/jquery.wikiEditor.js', 'version' => 195 ), array( 'src' => 'js/plugins/jquery.wikiEditor.highlight.js', 'version' => 53 ), - array( 'src' => 'js/plugins/jquery.wikiEditor.toolbar.js', 'version' => 70 ), + array( 'src' => 'js/plugins/jquery.wikiEditor.toolbar.js', 'version' => 71 ), array( 'src' => 'js/plugins/jquery.wikiEditor.dialogs.js', 'version' => 28 ), array( 'src' => 'js/plugins/jquery.wikiEditor.toc.js', 'version' => 98 ), array( 'src' => 'js/plugins/jquery.wikiEditor.preview.js', 'version' => 12 ), @@ -82,10 +82,10 @@ array( 'src' => 'js/thirdparty/contentCollector.js', 'version' => 2 ), ), 'combined' => array( - array( 'src' => 'js/plugins.combined.js', 'version' => 445 ), + array( 'src' => 'js/plugins.combined.js', 'version' => 446 ), ), 'minified' => array( - array( 'src' => 'js/plugins.combined.min.js', 'version' => 455 ), + array( 'src' => 'js/plugins.combined.min.js', 'version' => 456 ), ), ), ); Modified: trunk/extensions/UsabilityInitiative/js/plugins/jquery.wikiEditor.toolbar.js === --- trunk/extensions/UsabilityInitiative/js/plugins/jquery.wikiEditor.toolbar.js 2010-07-01 17:52:33 UTC (rev 68840) +++ trunk/extensions/UsabilityInitiative/js/plugins/jquery.wikiEditor.toolbar.js 2010-07-01 17:53:40 UTC (rev 68841) @@ -497,8 +497,8 @@ } if ( 'characters' in page ) { var html = ''; - for ( character in page.characters ) { - html += $.wikiEditor.modules.toolbar.fn.buildCharacter( page.characters[character], actions ); + for ( var i = 0; i < page.characters.length; i++ ) { + html += $.wikiEditor.modules.toolbar.fn.buildCharacter( page.characters[i], actions ); } $characters .html( html ) Modified: trunk/extensions/UsabilityInitiative/js/plugins.combined.js === --- trunk/extensions/UsabilityInitiative/js/plugins.combined.js 2010-07-01 17:52:33 UTC (rev 68840) +++ trunk/extensions/UsabilityInitiative/js/plugins.combined.js 2010-07-01 17:53:40 UTC (rev 68841) @@ -6671,8 +6671,8 @@ } if ( 'characters' in page ) { var html = ''; - for ( character in page.characters ) { - html += $.wikiEditor.modules.toolbar.fn.buildCharacter( page.characters[character], actions ); + for ( var i = 0; i < page.characters.length; i++ ) { + html += $.wikiEditor.modules.toolbar.fn.buildCharacter( page.characters[i], actions ); } $characters .html( html ) Modified: trunk/extensions/UsabilityIni
[MediaWiki-CVS] SVN: [68840] trunk/extensions/UsabilityInitiative/Vector/Modules/ EditWarning/EditWarning.i18n.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68840 Revision: 68840 Author: catrope Date: 2010-07-01 17:52:33 + (Thu, 01 Jul 2010) Log Message: --- EditWarning: Another {{int:}} -> actual message I seem to have missed earlier Modified Paths: -- trunk/extensions/UsabilityInitiative/Vector/Modules/EditWarning/EditWarning.i18n.php Modified: trunk/extensions/UsabilityInitiative/Vector/Modules/EditWarning/EditWarning.i18n.php === --- trunk/extensions/UsabilityInitiative/Vector/Modules/EditWarning/EditWarning.i18n.php 2010-07-01 16:26:11 UTC (rev 68839) +++ trunk/extensions/UsabilityInitiative/Vector/Modules/EditWarning/EditWarning.i18n.php 2010-07-01 17:52:33 UTC (rev 68840) @@ -772,7 +772,7 @@ */ $messages['zh-hans'] = array( 'vector-editwarning-warning' => '离开这个页面可能会令您失去之前的所有更改。 -若您已经登入,您可在您参数设置的“编辑”节中关闭此警告。', +若您已经登入,您可在您参数设置的“{{int:prefs-editing}}”节中关闭此警告。', 'vector-editwarning-preference' => '如在更改未保存时离开页面,则发出警告', ); ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68831] trunk/phase3/includes/installer
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68831 Revision: 68831 Author: demon Date: 2010-07-01 13:43:05 + (Thu, 01 Jul 2010) Log Message: --- Followup r63389: remove useless CACHE_DB and confusing CACHE_ANYTHING from cache setup Modified Paths: -- trunk/phase3/includes/installer/Installer.i18n.php trunk/phase3/includes/installer/WebInstaller.php Modified: trunk/phase3/includes/installer/Installer.i18n.php === --- trunk/phase3/includes/installer/Installer.i18n.php 2010-07-01 13:30:24 UTC (rev 68830) +++ trunk/phase3/includes/installer/Installer.i18n.php 2010-07-01 13:43:05 UTC (rev 68831) @@ -406,8 +406,6 @@ No functionality is removed, but speed may be impacted.', 'config-cache-accel' => 'PHP object caching (APC, eAccelerator, XCache or WinCache)', 'config-cache-memcached' => 'Use Memcached (requires additional setup and configuration)', - 'config-cache-db' => 'Cache data into the database', - 'config-cache-anything' => 'MediaWiki will attempt to cache data anywhere possible, except in Memcached, unless indicated explicitely', 'config-memcached-servers'=> 'Memcached servers:', 'config-memcached-help' => 'List of IP addresses to use for Memcached. Should be separated with commas and specify the port to be used (for example: 1.2.3.4:56, 7.8.9.10:11).', Modified: trunk/phase3/includes/installer/WebInstaller.php === --- trunk/phase3/includes/installer/WebInstaller.php2010-07-01 13:30:24 UTC (rev 68830) +++ trunk/phase3/includes/installer/WebInstaller.php2010-07-01 13:43:05 UTC (rev 68831) @@ -1406,8 +1406,7 @@ $this->parent->getFieldsetEnd() ); - $caches = array( 'none', 'anything', 'db' ); - $selected = 'db'; + $caches = array( 'none' ); if( count( $this->getVar( '_Caches' ) ) ) { $caches[] = 'accel'; $selected = 'accel'; ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68839] trunk/extensions/Translate/groups/OpenStreetMap/OpenStreetMap. yml
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68839 Revision: 68839 Author: siebrand Date: 2010-07-01 16:26:11 + (Thu, 01 Jul 2010) Log Message: --- Update optionals Modified Paths: -- trunk/extensions/Translate/groups/OpenStreetMap/OpenStreetMap.yml Modified: trunk/extensions/Translate/groups/OpenStreetMap/OpenStreetMap.yml === --- trunk/extensions/Translate/groups/OpenStreetMap/OpenStreetMap.yml 2010-07-01 16:20:55 UTC (rev 68838) +++ trunk/extensions/Translate/groups/OpenStreetMap/OpenStreetMap.yml 2010-07-01 16:26:11 UTC (rev 68839) @@ -49,6 +49,7 @@ - layouts.license.alt - layouts.project_name.h1 - layouts.project_name.title +- notifier.message_notification.subject_header - printable_name.with_version - site.edit.anon_edits # Users may or may not want to translate the OSM wiki too ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68838] trunk/WikiWord/WikiWordWeb/src/main/www
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68838 Revision: 68838 Author: daniel Date: 2010-07-01 16:20:55 + (Thu, 01 Jul 2010) Log Message: --- several fixes of stuff i broke when refactoring Modified Paths: -- trunk/WikiWord/WikiWordWeb/src/main/www/common/wwclient.php trunk/WikiWord/WikiWordWeb/src/main/www/wikipics/form.html.php trunk/WikiWord/WikiWordWeb/src/main/www/wikipics/response.html.php trunk/WikiWord/WikiWordWeb/src/main/www/wikipics/search.php Modified: trunk/WikiWord/WikiWordWeb/src/main/www/common/wwclient.php === --- trunk/WikiWord/WikiWordWeb/src/main/www/common/wwclient.php 2010-07-01 15:31:54 UTC (rev 68837) +++ trunk/WikiWord/WikiWordWeb/src/main/www/common/wwclient.php 2010-07-01 16:20:55 UTC (rev 68838) @@ -99,7 +99,7 @@ 'query' => 'info', 'gcid' => $id, 'lang' => $lang, - 'fields' => fields, + 'fields' => $fields, 'rclang' => $rclang ); Modified: trunk/WikiWord/WikiWordWeb/src/main/www/wikipics/form.html.php === --- trunk/WikiWord/WikiWordWeb/src/main/www/wikipics/form.html.php 2010-07-01 15:31:54 UTC (rev 68837) +++ trunk/WikiWord/WikiWordWeb/src/main/www/wikipics/form.html.php 2010-07-01 16:20:55 UTC (rev 68838) @@ -22,7 +22,12 @@ - + + + + + + Note: this is a thesaurus lookup, not a full text search. Multiple words are handeled as a single phrase. Only exact matches of complete phrases will be found. Modified: trunk/WikiWord/WikiWordWeb/src/main/www/wikipics/response.html.php === --- trunk/WikiWord/WikiWordWeb/src/main/www/wikipics/response.html.php 2010-07-01 15:31:54 UTC (rev 68837) +++ trunk/WikiWord/WikiWordWeb/src/main/www/wikipics/response.html.php 2010-07-01 16:20:55 UTC (rev 68838) @@ -346,7 +346,7 @@ - WikiPics 0.1α (experimental) + http://wikimedia.de";>Wikimedia Deutschland e.V.
[MediaWiki-CVS] SVN: [68833] trunk
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68833 Revision: 68833 Author: ialex Date: 2010-07-01 14:52:31 + (Thu, 01 Jul 2010) Log Message: --- svn:eol-style native Property Changed: trunk/extensions/CentralNotice/patches/patch-notice_languages.sql trunk/extensions/LiquidThreads/js/lqt.toolbar.js trunk/extensions/LiquidThreads/schema-changes/thread_pending_relationship.sql trunk/extensions/LiquidThreads/schema-changes/thread_reactions.sql trunk/extensions/mw-editcount/EditCount.php trunk/extensions/wikidiff2/tests/002.phpt trunk/phase3/includes/installer/CliInstallerOutput.php Property changes on: trunk/extensions/CentralNotice/patches/patch-notice_languages.sql ___ Added: svn:eol-style + native Property changes on: trunk/extensions/LiquidThreads/js/lqt.toolbar.js ___ Added: svn:eol-style + native Property changes on: trunk/extensions/LiquidThreads/schema-changes/thread_pending_relationship.sql ___ Added: svn:eol-style + native Property changes on: trunk/extensions/LiquidThreads/schema-changes/thread_reactions.sql ___ Added: svn:eol-style + native Property changes on: trunk/extensions/mw-editcount/EditCount.php ___ Added: svn:eol-style + native Property changes on: trunk/extensions/wikidiff2/tests/002.phpt ___ Added: svn:eol-style + native Property changes on: trunk/phase3/includes/installer/CliInstallerOutput.php ___ Added: svn:eol-style + native ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68837] trunk/phase3/includes/GlobalFunctions.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68837 Revision: 68837 Author: demon Date: 2010-07-01 15:31:54 + (Thu, 01 Jul 2010) Log Message: --- Throw a wfDeprecated() on this since the last usage is gone in r68836 Modified Paths: -- trunk/phase3/includes/GlobalFunctions.php Modified: trunk/phase3/includes/GlobalFunctions.php === --- trunk/phase3/includes/GlobalFunctions.php 2010-07-01 15:29:15 UTC (rev 68836) +++ trunk/phase3/includes/GlobalFunctions.php 2010-07-01 15:31:54 UTC (rev 68837) @@ -2093,6 +2093,7 @@ * @deprecated */ function &wfGetMimeMagic() { + wfDeprecated( __FUNCTION__ ); return MimeMagic::singleton(); } ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68836] trunk/extensions/SocialProfile
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68836 Revision: 68836 Author: demon Date: 2010-07-01 15:29:15 + (Thu, 01 Jul 2010) Log Message: --- Please don't use functions that were deprecated 24309 revisions before you used them Modified Paths: -- trunk/extensions/SocialProfile/SystemGifts/SpecialSystemGiftManagerLogo.php trunk/extensions/SocialProfile/UserGifts/SpecialGiftManagerLogo.php Modified: trunk/extensions/SocialProfile/SystemGifts/SpecialSystemGiftManagerLogo.php === --- trunk/extensions/SocialProfile/SystemGifts/SpecialSystemGiftManagerLogo.php 2010-07-01 15:18:46 UTC (rev 68835) +++ trunk/extensions/SocialProfile/SystemGifts/SpecialSystemGiftManagerLogo.php 2010-07-01 15:29:15 UTC (rev 68836) @@ -670,7 +670,7 @@ */ function verify( $tmpfile, $extension ) { # magically determine mime type - $magic = & wfGetMimeMagic(); + $magic = MimeMagic::singleton(); $mime = $magic->guessMimeType( $tmpfile, false ); # check mime type, if desired @@ -714,7 +714,7 @@ * @return bool */ function verifyExtension( $mime, $extension ) { - $magic =& wfGetMimeMagic(); + $magic = MimeMagic::singleton(); if ( !$mime || $mime == 'unknown' || $mime == 'unknown/unknown' ) if ( !$magic->isRecognizableExtension( $extension ) ) { Modified: trunk/extensions/SocialProfile/UserGifts/SpecialGiftManagerLogo.php === --- trunk/extensions/SocialProfile/UserGifts/SpecialGiftManagerLogo.php 2010-07-01 15:18:46 UTC (rev 68835) +++ trunk/extensions/SocialProfile/UserGifts/SpecialGiftManagerLogo.php 2010-07-01 15:29:15 UTC (rev 68836) @@ -658,7 +658,7 @@ */ function verify( $tmpfile, $extension ) { # magically determine mime type - $magic = & wfGetMimeMagic(); + $magic = MimeMagic::singleton(); $mime = $magic->guessMimeType( $tmpfile, false ); # check mime type, if desired @@ -703,7 +703,7 @@ * @return bool */ function verifyExtension( $mime, $extension ) { - $magic = & wfGetMimeMagic(); + $magic = MimeMagic::singleton(); if ( !$mime || $mime == 'unknown' || $mime == 'unknown/unknown' ) if ( !$magic->isRecognizableExtension( $extension ) ) { ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68835] trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68835 Revision: 68835 Author: demon Date: 2010-07-01 15:18:46 + (Thu, 01 Jul 2010) Log Message: --- Kill off a $wgTitle/$wgOut usage. Use the OutputPage provided by the hook Modified Paths: -- trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php Modified: trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php === --- trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php 2010-07-01 15:02:10 UTC (rev 68834) +++ trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php 2010-07-01 15:18:46 UTC (rev 68835) @@ -127,22 +127,23 @@ /** * Add FlaggedRevs css for relevant special pages. + * @param OutputPage $out */ - protected static function injectStyleForSpecial() { - global $wgTitle, $wgOut; - if ( empty( $wgTitle ) || $wgTitle->getNamespace() !== NS_SPECIAL ) { + protected static function injectStyleForSpecial( &$out ) { + $title = $out->getTitle(); + if ( $title->getNamespace() !== NS_SPECIAL ) { return true; } $spPages = array( 'UnreviewedPages', 'OldReviewedPages', 'ProblemChanges', 'Watchlist', 'Recentchanges', 'Contributions' ); foreach ( $spPages as $n => $key ) { - if ( $wgTitle->isSpecial( $key ) ) { + if ( $title->isSpecial( $key ) ) { global $wgScriptPath, $wgFlaggedRevsStylePath, $wgFlaggedRevStyleVersion; $stylePath = str_replace( '$wgScriptPath', $wgScriptPath, $wgFlaggedRevsStylePath ); $encCssFile = htmlspecialchars( "$stylePath/flaggedrevs.css?" . $wgFlaggedRevStyleVersion ); - $wgOut->addExtensionStyle( $encCssFile ); + $out->addExtensionStyle( $encCssFile ); break; } } @@ -152,15 +153,14 @@ /* * Add tag notice, CSS/JS, and set robots policy */ - public static function onBeforePageDisplay() { - global $wgOut; - if ( $wgOut->isArticleRelated() ) { + public static function onBeforePageDisplay( &$out, &$skin ) { + if ( $out->isArticleRelated() ) { $view = FlaggedArticleView::singleton(); $view->displayTag(); // show notice bar/icon in subtitle $view->setRobotPolicy(); // set indexing policy self::injectStyleAndJS(); // full CSS/JS } else { - self::injectStyleForSpecial(); // try special page CSS + self::injectStyleForSpecial( $out ); // try special page CSS } return true; } ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68834] branches/MwEmbedStandAlone/tests/selenium_tests/ EmbedPlayerLoadsTest.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68834 Revision: 68834 Author: papyromancer Date: 2010-07-01 15:02:10 + (Thu, 01 Jul 2010) Log Message: --- * basic player loading test is functioning Modified Paths: -- branches/MwEmbedStandAlone/tests/selenium_tests/EmbedPlayerLoadsTest.php Modified: branches/MwEmbedStandAlone/tests/selenium_tests/EmbedPlayerLoadsTest.php === --- branches/MwEmbedStandAlone/tests/selenium_tests/EmbedPlayerLoadsTest.php 2010-07-01 14:52:31 UTC (rev 68833) +++ branches/MwEmbedStandAlone/tests/selenium_tests/EmbedPlayerLoadsTest.php 2010-07-01 15:02:10 UTC (rev 68834) @@ -6,26 +6,24 @@ } // create test suite -$wgSeleniumTestSuites['SimpleSeleniumTest'] = new SeleniumTestSuite('Simple Selenium Test'); -$wgSeleniumTestSuites['SimpleSeleniumTest']->addTest(new SimpleSeleniumTest()); +$wgSeleniumTestSuites['EmbedPlayerLoadingTests'] = new SeleniumTestSuite('Embed Player Loading Test Suite'); +$wgSeleniumTestSuites['EmbedPlayerLoadingTests']->addTest(new EmbedPlayerLoads()); -class SimpleSeleniumTest extends SeleniumTestCase +class EmbedPlayerLoads extends SeleniumTestCase { - public $name = "Basic selenium test"; + public $name = "Embed Player Loading Test"; public function runTest() { global $wgSeleniumTestsWikiUrl; -$this->open($wgSeleniumTestsWikiUrl.'/tests/mwEmbed_Demo.html'); -// $this->type("wpTextbox1", "This is a basic test"); -// $this->click("wpPreview"); + $this->open($wgSeleniumTestsWikiUrl.'/modules/EmbedPlayer/tests/Player_Themeable.html'); + $this->waitForPageToLoad(1); + +$this->isElementPresent("//d...@class='interface_wrap k-player']", 1); +$this->isElementPresent("//d...@class='interface_wrap mv-player']", 1); +$this->isElementPresent("//d...@class='ui-state-default play-btn-large']", 1); - // check result - //$source = $this->getText("//d...@id='wikiPreview']/p"); - //$correct = strstr($source, "This is a basic test"); - //$this->assertEquals($correct, true); - } } ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68832] trunk/WikiWord/WikiWordWeb/src/main
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68832 Revision: 68832 Author: daniel Date: 2010-07-01 14:50:27 + (Thu, 01 Jul 2010) Log Message: --- better indexes for faster access Modified Paths: -- trunk/WikiWord/WikiWordWeb/src/main/maintenance/build-search-index.sh trunk/WikiWord/WikiWordWeb/src/main/maintenance/search-index.sql trunk/WikiWord/WikiWordWeb/src/main/www/common/wwclient.php trunk/WikiWord/WikiWordWeb/src/main/www/common/wwthesaurus.php trunk/WikiWord/WikiWordWeb/src/main/www/wikipics/search.php trunk/WikiWord/WikiWordWeb/src/main/www/wikiword/api.php Added Paths: --- trunk/WikiWord/WikiWordWeb/src/main/maintenance/resource-index.sql Removed Paths: - trunk/WikiWord/WikiWordWeb/src/main/maintenance/search-index-local.sql Modified: trunk/WikiWord/WikiWordWeb/src/main/maintenance/build-search-index.sh === --- trunk/WikiWord/WikiWordWeb/src/main/maintenance/build-search-index.sh 2010-07-01 13:43:05 UTC (rev 68831) +++ trunk/WikiWord/WikiWordWeb/src/main/maintenance/build-search-index.sh 2010-07-01 14:50:27 UTC (rev 68832) @@ -4,12 +4,9 @@ db="$1" collection="$2" thesaurus="$3" -languages="en de fr nl it es pt pl" -echo "preparing search index" +echo "building search index" replace '{collection}' "$collection" '{thesaurus}' "$thesaurus" < search-index.sql | mysql "$db" -for n in $languages; do -echo "collection search index: $n" -replace '{collection}' "$collection" '{thesaurus}' "$thesaurus" '{lang}' "$n" < search-index-local.sql | mysql "$db" -done +echo "building resource index" +replace '{collection}' "$collection" '{thesaurus}' "$thesaurus" < resource-index.sql | mysql "$db" Added: trunk/WikiWord/WikiWordWeb/src/main/maintenance/resource-index.sql === --- trunk/WikiWord/WikiWordWeb/src/main/maintenance/resource-index.sql (rev 0) +++ trunk/WikiWord/WikiWordWeb/src/main/maintenance/resource-index.sql 2010-07-01 14:50:27 UTC (rev 68832) @@ -0,0 +1,14 @@ +create table if not exists {collection}_{thesaurus}_resource_index ( + concept int(11) NOT NULL, + resources MEDIUMBLOB int(11) NOT NULL, + PRIMARY KEY ( concept ), + ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin; + +truncate {collection}_{thesaurus}_resource_index; + +-- collect ressources in all languages +insert into {collection}_{thesaurus}_resource_index ( + concept, resources +select concept, group_concat(distinct concat(type, ":", lang, ":", local_resource_name) separator "|" ) as resources +from {collection}_{thesaurus}_about as A +where type > 0; Deleted: trunk/WikiWord/WikiWordWeb/src/main/maintenance/search-index-local.sql === --- trunk/WikiWord/WikiWordWeb/src/main/maintenance/search-index-local.sql 2010-07-01 13:43:05 UTC (rev 68831) +++ trunk/WikiWord/WikiWordWeb/src/main/maintenance/search-index-local.sql 2010-07-01 14:50:27 UTC (rev 68832) @@ -1,16 +0,0 @@ --- collect definitions -insert into {collection}_{thesaurus}_search_index ( - concept, concept_name, `type`, - `lang`, `term`, `score`, `norm` ) -select O.global_concept, M.concept_name, C.type, "{lang}", - REPLACE( LCASE( CAST(M.term_text as CHAR CHARACTER SET utf8) COLLATE utf8_general_ci ), "-", "" ), - M.rule * M.freq, 1 -from {collection}_{lang}_meaning as M -join {collection}_{thesaurus}_origin as O on O.lang = "{lang}" and O.local_concept = M.concept -join {collection}_{thesaurus}_concept as C on C.id = O.global_concept -where (M.rule not in (10, 30) OR M.freq > 1) and C.type > 0 -on duplicate key update - score = if (score > values(score), score, values(score)), - norm = if (norm < values(norm), score, values(norm)); - --- FIXME: normalization levels! 0=none, 1=case-and-dash (+translit?), 2=whitespace-and-punctuation, 4=soundex \ No newline at end of file Modified: trunk/WikiWord/WikiWordWeb/src/main/maintenance/search-index.sql === --- trunk/WikiWord/WikiWordWeb/src/main/maintenance/search-index.sql 2010-07-01 13:43:05 UTC (rev 68831) +++ trunk/WikiWord/WikiWordWeb/src/main/maintenance/search-index.sql 2010-07-01 14:50:27 UTC (rev 68832) @@ -11,3 +11,19 @@ ) ENGINE=MyISAM DEFAULT CHARSET=utf8 COLLATE=utf8_bin; truncate {collection}_{thesaurus}_search_index; + +-- collect definitions +insert into {collection}_{thesaurus}_search_index ( + concept, concept_name, `type`, `lang`, `term`, `score`, `norm` ) +select C.id, O.local_concept_name, C.type, M.lang, + REPLACE( LCASE( CAST(M.term_text as CHAR CHARACTER SET utf8) COLLATE utf8_general_ci ), "-", "" ), + M.rule * M.freq, 1 +from {collection}_{thesaurus}_meaning as M +join {collection}_{thesaurus}_conce
[MediaWiki-CVS] SVN: [68830] trunk/extensions/FlaggedRevs
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68830 Revision: 68830 Author: demon Date: 2010-07-01 13:30:24 + (Thu, 01 Jul 2010) Log Message: --- (bug 24004) Add magic word like {{protectionlevel}} for pending changes. So here's {{pendingchangelevel}} Modified Paths: -- trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php trunk/extensions/FlaggedRevs/FlaggedRevs.php Modified: trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php === --- trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php 2010-07-01 11:42:52 UTC (rev 68829) +++ trunk/extensions/FlaggedRevs/FlaggedRevs.hooks.php 2010-07-01 13:30:24 UTC (rev 68830) @@ -632,9 +632,29 @@ public static function onLanguageGetMagic( &$magicWords, $langCode ) { $magicWords['pagesusingpendingchanges'] = array( 0, 'pagesusingpendingchanges' ); + $magicWords['pendingchangelevel'] = + array( 0, 'pendingchangelevel' ); return true; } + public static function onParserGetVariableValueSwitch( &$parser, &$cache, &$word, &$ret ) { + if( $word == 'pendingchangelevel' ) { + $title = $parser->getTitle(); + if( !FlaggedRevs::inReviewNamespace( $title ) ) { + $ret = ''; + } else { + $config = FlaggedRevs::getPageVisibilitySettings( $title ); + $ret = $config['autoreview']; + } + } + return true; + } + + public static function onMagicWordwgVariableIDs( &$words ) { + $words[] = 'pendingchangelevel'; + return true; + } + public static function parserPagesUsingPendingChanges( &$parser, $ns = '' ) { $nsList = FlaggedRevs::getReviewNamespaces(); Modified: trunk/extensions/FlaggedRevs/FlaggedRevs.php === --- trunk/extensions/FlaggedRevs/FlaggedRevs.php2010-07-01 11:42:52 UTC (rev 68829) +++ trunk/extensions/FlaggedRevs/FlaggedRevs.php2010-07-01 13:30:24 UTC (rev 68830) @@ -539,6 +539,8 @@ # Parser stuff $wgHooks['ParserFirstCallInit'][] = 'FlaggedRevsHooks::onParserFirstCallInit'; $wgHooks['LanguageGetMagic'][] = 'FlaggedRevsHooks::onLanguageGetMagic'; + $wgHooks['ParserGetVariableValueSwitch'][] = 'FlaggedRevsHooks::onParserGetVariableValueSwitch'; + $wgHooks['MagicWordwgVariableIDs'][] = 'FlaggedRevsHooks::onMagicWordwgVariableIDs'; } # Give bots the 'autoreview' right (here so it triggers after CentralAuth) # @TODO: better way to ensure hook order ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68828] trunk/extensions/Maps
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68828 Revision: 68828 Author: jeroendedauw Date: 2010-07-01 11:42:44 + (Thu, 01 Jul 2010) Log Message: --- Patch to enable KML for google maps submitted by 67.170.217.247 Modified Paths: -- trunk/extensions/Maps/Maps.php trunk/extensions/Maps/Services/GoogleMaps/GoogleMapFunctions.js trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMaps.php trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMapsDispMap.php trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMapsDispPoint.php Modified: trunk/extensions/Maps/Maps.php === --- trunk/extensions/Maps/Maps.php 2010-07-01 11:04:00 UTC (rev 68827) +++ trunk/extensions/Maps/Maps.php 2010-07-01 11:42:44 UTC (rev 68828) @@ -33,7 +33,7 @@ echo 'Warning: You need to have http://www.mediawiki.org/wiki/Extension:Validator";>Validator installed in order to use http://www.mediawiki.org/wiki/Extension:Maps";>Maps.'; } else { - define( 'Maps_VERSION', '0.6.4 a3' ); + define( 'Maps_VERSION', '0.6.4 a4' ); // The different coordinate notations. define( 'Maps_COORDS_FLOAT', 'float' ); Modified: trunk/extensions/Maps/Services/GoogleMaps/GoogleMapFunctions.js === --- trunk/extensions/Maps/Services/GoogleMaps/GoogleMapFunctions.js 2010-07-01 11:04:00 UTC (rev 68827) +++ trunk/extensions/Maps/Services/GoogleMaps/GoogleMapFunctions.js 2010-07-01 11:42:44 UTC (rev 68828) @@ -140,7 +140,10 @@ break; case 'nav-label' : case 'nav' : map.addControl(new GNavLabelControl()); - break; + break; + case 'searchbar' : + map.enableGoogleBar(); + break; } } @@ -163,6 +166,11 @@ map.enableContinuousZoom(); + // Code to add KML files + if (mapOptions.kml != '') { + map.addOverlay( new GGeoXml( mapOptions.kml ) ); + } + // Make the map variable available for other functions if (!window.GMaps) window.GMaps = new Object; eval("window.GMaps." + mapName + " = map;"); Modified: trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMaps.php === --- trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMaps.php 2010-07-01 11:04:00 UTC (rev 68827) +++ trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMaps.php 2010-07-01 11:42:44 UTC (rev 68828) @@ -72,6 +72,8 @@ 'default' => $egMapsGoogleAutozoom, 'output-type' => 'boolstr' ), + 'kml' => array( + ), ); $parameters['zoom']['criteria']['in_range'] = array( 0, 20 ); @@ -119,7 +121,7 @@ public static function getControlNames() { return array( 'auto', 'large', 'small', 'large-original', 'small-original', 'zoom', 'type', 'type-menu', - 'overlays', 'overview', 'overview-map', 'scale', 'nav-label', 'nav' + 'overlays', 'overview', 'overview-map', 'scale', 'nav-label', 'nav', 'searchbar' ); } Modified: trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMapsDispMap.php === --- trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMapsDispMap.php 2010-07-01 11:04:00 UTC (rev 68827) +++ trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMapsDispMap.php 2010-07-01 11:42:44 UTC (rev 68828) @@ -83,7 +83,8 @@ type: $this->type, types: [$this->types], controls: [$this->controls], - scrollWheelZoom: $this->autozoom + scrollWheelZoom: $this->autozoom, + kml: '$this->kml' }, []); } Modified: trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMapsDispPoint.php === --- trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMapsDispPoint.php 2010-07-01 11:04:00 UTC (rev 68827) +++ trunk/extensions/Maps/Services/GoogleMaps/Maps_GoogleMapsDispPoint.php 2010-07-01 11:42:44 UTC (rev 68828) @@ -86,7 +86,8 @@ type: $this->type, types: [$this->types], controls: [$this->controls], - scrollWheelZoom: $this->autozoom
[MediaWiki-CVS] SVN: [68823] trunk/extensions/AuthorProtect/AuthorProtect.i18n.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68823 Revision: 68823 Author: raymond Date: 2010-07-01 09:22:56 + (Thu, 01 Jul 2010) Log Message: --- Reword/Add colon to labels for consistenzy Modified Paths: -- trunk/extensions/AuthorProtect/AuthorProtect.i18n.php Modified: trunk/extensions/AuthorProtect/AuthorProtect.i18n.php === --- trunk/extensions/AuthorProtect/AuthorProtect.i18n.php 2010-07-01 09:17:24 UTC (rev 68822) +++ trunk/extensions/AuthorProtect/AuthorProtect.i18n.php 2010-07-01 09:22:56 UTC (rev 68823) @@ -18,8 +18,8 @@ 'authorprotect-confirm'=> 'Change protection levels', 'authorprotect-edit' => 'Restrict editing to authors', 'authorprotect-move' => 'Restrict moving to authors', - 'authorprotect-expiry' => 'Expiration time', - 'authorprotect-reason' => 'Reason', + 'authorprotect-expiry' => 'Expires:', + 'authorprotect-reason' => 'Reason:', 'authorprotect-intro' => 'Use this form to lock this page from non-authors', 'authorprotect-success'=> 'Protection successful!', 'authorprotect-failure'=> 'Protection unsuccessful', ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68822] trunk/extensions/AuthorProtect/AuthorProtect.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68822 Revision: 68822 Author: raymond Date: 2010-07-01 09:17:24 + (Thu, 01 Jul 2010) Log Message: --- Follow-up r68820: Fix another warning and a fatal error Modified Paths: -- trunk/extensions/AuthorProtect/AuthorProtect.php Modified: trunk/extensions/AuthorProtect/AuthorProtect.php === --- trunk/extensions/AuthorProtect/AuthorProtect.php2010-07-01 08:25:04 UTC (rev 68821) +++ trunk/extensions/AuthorProtect/AuthorProtect.php2010-07-01 09:17:24 UTC (rev 68822) @@ -96,7 +96,7 @@ return true; } -function efAuthorProtectForm( $action, &$article ) { +function efAuthorProtectForm( $action, $article ) { global $wgTitle, $wgAuthorProtectDoProtect; if ( $action == 'authorprotect' ) { wfLoadExtensionMessages( 'AuthorProtect' ); @@ -110,7 +110,7 @@ if ( !$wgUser->matchEditToken( $wgRequest->getText( 'wpToken' ) ) ) { $wgOut->setPageTitle( wfMsg( 'errorpagetitle' ) ); $wgOut->addWikiText( wfMsg( 'sessionfailure' ) ); - return; + return false; } $restrictions = array(); $expiration = array(); ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68821] trunk/extensions/examples
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68821 Revision: 68821 Author: nikerabbit Date: 2010-07-01 08:25:04 + (Thu, 01 Jul 2010) Log Message: --- Update examples from stone age Modified Paths: -- trunk/extensions/examples/Content_action.php trunk/extensions/examples/FourFileTemplate/MyExtension.php trunk/extensions/examples/FourFileTemplate/MyExtension_body.php trunk/extensions/examples/Parser_function.php trunk/extensions/examples/Parser_hook.php trunk/extensions/examples/SpecialIncludable.php trunk/extensions/examples/Variable_hook.php Modified: trunk/extensions/examples/Content_action.php === --- trunk/extensions/examples/Content_action.php2010-07-01 08:05:49 UTC (rev 68820) +++ trunk/extensions/examples/Content_action.php2010-07-01 08:25:04 UTC (rev 68821) @@ -19,6 +19,8 @@ function wfAddaction() { global $wgHooks, $wgMessageCache; + // This is not the proper way to do i18n + // See FourFileTemplate how to do i18n $wgMessageCache->addMessage( 'myact', 'My action' ); $wgHooks['SkinTemplateContentActions'][] = 'wfAddactionContentHook'; $wgHooks['UnknownAction'][] = 'wfAddactActionHook'; @@ -31,7 +33,7 @@ if ( $wgTitle->getNamespace() != NS_SPECIAL ) { $content_actions['myact'] = array( - 'class' => $action == 'myact' ? 'selected' : false, + 'class' => $action === 'myact' ? 'selected' : false, 'text' => wfMsg( 'myact' ), 'href' => $wgTitle->getLocalUrl( 'action=myact' ) ); @@ -45,8 +47,9 @@ $title = $wgArticle->getTitle(); - if ( $action == 'myact' ) - $wgOut->addHTML( 'The page name is ' . $title->getText() . ' and you are ' . $wgArticle->getUserText() ); + if ( $action === 'myact' ) { + $wgOut->addWikiText( 'The page name is ' . $title->getText() . ' and you are ' . $wgArticle->getUserText() ); + } return false; } Modified: trunk/extensions/examples/FourFileTemplate/MyExtension.php === --- trunk/extensions/examples/FourFileTemplate/MyExtension.php 2010-07-01 08:05:49 UTC (rev 68820) +++ trunk/extensions/examples/FourFileTemplate/MyExtension.php 2010-07-01 08:25:04 UTC (rev 68821) @@ -12,6 +12,7 @@ 'path' => __FILE__, 'name' => 'MyExtensionName', 'version' => '0.1', + // You can use array for multiple authors 'author' => 'MyExtensionAuthor', 'url' => 'http://www.mediawiki.org/wiki/Extension:MyExtension', 'descriptionmsg' => 'myextension-desc', Modified: trunk/extensions/examples/FourFileTemplate/MyExtension_body.php === --- trunk/extensions/examples/FourFileTemplate/MyExtension_body.php 2010-07-01 08:05:49 UTC (rev 68820) +++ trunk/extensions/examples/FourFileTemplate/MyExtension_body.php 2010-07-01 08:25:04 UTC (rev 68821) @@ -1,6 +1,5 @@ setHeaders(); - wfLoadExtensionMessages( 'MyExtension' ); - # Get request data from, e.g. $param = $wgRequest->getText( 'param' ); Modified: trunk/extensions/examples/Parser_function.php === --- trunk/extensions/examples/Parser_function.php 2010-07-01 08:05:49 UTC (rev 68820) +++ trunk/extensions/examples/Parser_function.php 2010-07-01 08:25:04 UTC (rev 68821) @@ -15,14 +15,14 @@ } # Define a setup function -$wgExtensionFunctions[] = 'wfExampleParserFunction_Setup'; +$wgHooks['ParserFirstCallInit'][] = 'wfExampleParserFunction_Setup'; # Add a hook to initialise the magic word -$wgHooks['LanguageGetMagic'][] = 'wfExampleParserFunction_Magic'; +$wgHooks['LanguageGetMagic'][] = 'wfExampleParserFunction_Magic'; -function wfExampleParserFunction_Setup() { - global $wgParser; +function wfExampleParserFunction_Setup( $parser ) { # Set a function hook associating the "example" magic word with our function - $wgParser->setFunctionHook( 'example', 'wfExampleParserFunction_Render' ); + $parser->setFunctionHook( 'example', 'wfExampleParserFunction_Render' ); + return true; } function wfExampleParserFunction_Magic( &$magicWords, $langCode ) { Modified: trunk/extensions/examples/Parser_hook.php === --- trunk/extensions/examples/Parser_hook.php 2010-07-01 08:05:49 UTC (rev 68820) +++ trunk/extensions/examples/Parser_hook.php 2010-07-01 08:25:04 UTC (rev 68821) @@ -8,11 +8,11 @@ * @ingroup Extensions * * @author Ævar Arnfjörð Bjarmason + * @author Niklas Laxström * @copyright Copyright © 2005, Ævar Arnfjörð Bjarmason *
[MediaWiki-CVS] SVN: [68820] trunk/extensions/AuthorProtect/AuthorProtect.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68820 Revision: 68820 Author: raymond Date: 2010-07-01 08:05:49 + (Thu, 01 Jul 2010) Log Message: --- Fix Warning: Parameter 1 to efAssignAuthor() expected to be a reference, value given in D:\F_Programmierung\xampp\htdocs\wiki2\includes\Hooks.php on line 133 Modified Paths: -- trunk/extensions/AuthorProtect/AuthorProtect.php Modified: trunk/extensions/AuthorProtect/AuthorProtect.php === --- trunk/extensions/AuthorProtect/AuthorProtect.php2010-07-01 07:42:43 UTC (rev 68819) +++ trunk/extensions/AuthorProtect/AuthorProtect.php2010-07-01 08:05:49 UTC (rev 68820) @@ -53,7 +53,7 @@ return true; } -function efAssignAuthor( &$user, &$aRights ) { +function efAssignAuthor( $user, &$aRights ) { // don't assign author to anons... messes up logging stuff. // plus it's all user_id based so it is impossible to differentiate one anon from another if ( userIsAuthor() && $user->isLoggedIn() ) { ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68818] trunk/phase3/includes/SpecialPage.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68818 Revision: 68818 Author: nikerabbit Date: 2010-07-01 07:30:55 + (Thu, 01 Jul 2010) Log Message: --- Don't add confusing new lines to debug output, mark deprecated method Modified Paths: -- trunk/phase3/includes/SpecialPage.php Modified: trunk/phase3/includes/SpecialPage.php === --- trunk/phase3/includes/SpecialPage.php 2010-07-01 07:13:19 UTC (rev 68817) +++ trunk/phase3/includes/SpecialPage.php 2010-07-01 07:30:55 UTC (rev 68818) @@ -308,8 +308,10 @@ * an associative record to $wgSpecialPages. This avoids autoloading SpecialPage. * * @param $page SpecialPage +* Deprecated in 1.7, warnings in 1.17, might be removed in 1.20 */ static function addPage( &$page ) { + wfDeprecated( __METHOD__ ); if ( !self::$mListInitialised ) { self::initList(); } @@ -624,16 +626,16 @@ $found = false; foreach ( $aliases as $n => $values ) { if ( strcasecmp( $name, $n ) === 0 ) { - wfWarn( "Found alias defined for $n when searching for special page aliases -for $name. Case mismatch?" ); + wfWarn( "Found alias defined for $n when searching for" . + "special page aliases for $name. Case mismatch?" ); $name = $values[0]; $found = true; break; } } if ( !$found ) { - wfWarn( "Did not find alias for special page '$name'. -Perhaps no page aliases are defined for it?" ); + wfWarn( "Did not find alias for special page '$name'." . + "Perhaps no aliases are defined for it?" ); } } if ( $subpage !== false && !is_null( $subpage ) ) { ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs
[MediaWiki-CVS] SVN: [68817] trunk/extensions/Translate/tag/SpecialPageTranslation.php
http://www.mediawiki.org/wiki/Special:Code/MediaWiki/68817 Revision: 68817 Author: nikerabbit Date: 2010-07-01 07:13:19 + (Thu, 01 Jul 2010) Log Message: --- Fix more bugs caused by strict comparisons and wrong types Modified Paths: -- trunk/extensions/Translate/tag/SpecialPageTranslation.php Modified: trunk/extensions/Translate/tag/SpecialPageTranslation.php === --- trunk/extensions/Translate/tag/SpecialPageTranslation.php 2010-07-01 06:28:30 UTC (rev 68816) +++ trunk/extensions/Translate/tag/SpecialPageTranslation.php 2010-07-01 07:13:19 UTC (rev 68817) @@ -158,10 +158,12 @@ foreach ( $res as $r ) { if ( !isset( $pages[$r->page_id] ) ) { $pages[$r->page_id] = array(); - $pages[$r->page_id]['title'] = Title::newFromRow( $r ); + $title = Title::newFromRow( $r ); + $pages[$r->page_id]['title'] = $title; + $pages[$r->page_id]['latest'] = intval( $title->getLatestRevID() ); } - $pages[$r->page_id][$r->rtt_name] = $r->rt_revision; + $pages[$r->page_id][$r->rtt_name] = intval( $r->rt_revision ); } // Pages where mark <= tag @@ -171,7 +173,7 @@ continue; } - if ( $page['tp:tag'] !== $page['title']->getLatestRevID() ) { + if ( $page['tp:tag'] !== $page['latest'] ) { continue; } @@ -179,7 +181,7 @@ if ( $page['tp:mark'] !== $page['tp:tag'] ) { $link = "$link"; } - $acts = $this->actionLinks( $page['title'], $page['tp:mark'], 'old' ); + $acts = $this->actionLinks( $page['title'], $page['tp:mark'], $page['latest'], 'old' ); $items[] = "$link ($acts) "; unset( $pages[$index] ); } @@ -199,13 +201,13 @@ /* Ignore pages which have had at some point, but which * have never been marked. */ - if ( $page['title']->getLatestRevID() !== $page['tp:tag'] ) { + if ( $page['tp:tag'] !== $page['latest'] ) { unset( $pages[$index] ); continue; } $link = $this->user->getSkin()->link( $page['title'] ); - $acts = $this->actionLinks( $page['title'], $page['tp:tag'], 'new' ); + $acts = $this->actionLinks( $page['title'], $page['tp:tag'], $page['latest'], 'new' ); $items[] = "$link ($acts) "; unset( $pages[$index] ); @@ -222,7 +224,7 @@ $items = array(); foreach ( $pages as $index => $page ) { $link = $this->user->getSkin()->link( $page['title'] ); - $acts = $this->actionLinks( $page['title'], $page['tp:tag'], 'stuck' ); + $acts = $this->actionLinks( $page['title'], $page['tp:tag'], $page['latest'], 'stuck' ); $items[] = "$link ($acts) "; unset( $pages[$index] ); @@ -235,10 +237,9 @@ } } - protected function actionLinks( $title, $rev, $old = 'old' ) { + protected function actionLinks( $title, $rev, $latest, $old = 'old' ) { $actions = array(); - $latest = $title->getLatestRevId(); /* For pages that have been marked for translation at some point, * but there has been new changes since then, provide a link to * to view the differences between last marked version and latest ___ MediaWiki-CVS mailing list MediaWiki-CVS@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-cvs