r78096 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r78095‎ | r78096 | r78097 >
Date:21:17, 8 December 2010
Author:catrope
Status:ok
Tags:
Comment:
1.17: Merge recent fixes tagged on CodeReview, except for problematic revisions (fixme's, followups to fixme's, or revs I didn't deem worthy of merging). Merged revs: r77988, r77999, r78006, r78007, r78009, r78012, r78018, r78022, r78046, r78052, r78070, r78071, r78081, r78083, r78085, r78088, r78089
Modified paths:
  • /branches/REL1_17/extensions/CentralAuth/SpecialGlobalUsers.php (modified) (history)
  • /branches/REL1_17/extensions/FlaggedRevs/FlaggedRevision.php (modified) (history)
  • /branches/REL1_17/extensions/UploadWizard/resources/combined.js (modified) (history)
  • /branches/REL1_17/extensions/UploadWizard/resources/combined.min.js (modified) (history)
  • /branches/REL1_17/extensions/WikiEditor/modules/jquery.wikiEditor.templateEditor.js (modified) (history)
  • /branches/REL1_17/phase3/RELEASE-NOTES (modified) (history)
  • /branches/REL1_17/phase3/includes/CategoryPage.php (modified) (history)
  • /branches/REL1_17/phase3/includes/DjVuImage.php (modified) (history)
  • /branches/REL1_17/phase3/includes/GlobalFunctions.php (modified) (history)
  • /branches/REL1_17/phase3/includes/OutputPage.php (modified) (history)
  • /branches/REL1_17/phase3/includes/installer/Installer.i18n.php (modified) (history)
  • /branches/REL1_17/phase3/includes/installer/Installer.php (modified) (history)
  • /branches/REL1_17/phase3/includes/upload/UploadFromUrl.php (modified) (history)
  • /branches/REL1_17/phase3/maintenance/tests/phpunit/phpunit.php (modified) (history)
  • /branches/REL1_17/phase3/resources/jquery.ui/themes/vector/jquery.ui.button.css (modified) (history)
  • /branches/REL1_17/phase3/resources/jquery.ui/themes/vector/jquery.ui.dialog.css (modified) (history)
  • /branches/REL1_17/phase3/resources/jquery/jquery.tipsy.js (deleted) (history)
  • /branches/REL1_17/phase3/trackback.php (modified) (history)

Diff [purge]

Index: branches/REL1_17/extensions/WikiEditor/modules/jquery.wikiEditor.templateEditor.js
@@ -253,7 +253,7 @@
254254 $template.parent().attr('contentEditable', 'false');
255255 }
256256
257 - $template.click( function(event) {event.preventDefault(); return false;}; )
 257+ $template.click( function(event) {event.preventDefault(); return false;} );
258258
259259 $template.find( '.wikiEditor-template-name' )
260260 .click( function( event ) {
Index: branches/REL1_17/extensions/UploadWizard/resources/combined.js
@@ -11775,7 +11775,7 @@
1177611776
1177711777 wikiText += "=={{int:filedesc}}==\n";
1177811778
11779 - wikiText += '{{Information\n' + info + '}}\n';
 11779+ wikiText += '{{Information\n' + info + '}}\n\n';
1178011780
1178111781 // add a location template if possible
1178211782
@@ -11783,14 +11783,14 @@
1178411784 var otherInfoWikiText = $j( _this.otherInformationInput ).val().trim();
1178511785 if ( ! mw.isEmpty( otherInfoWikiText ) ) {
1178611786 wikiText += "=={{int:otherinfo}}==\n";
11787 - wikiText += otherInfoWikiText;
 11787+ wikiText += otherInfoWikiText + "\n\n";
1178811788 }
1178911789
1179011790 wikiText += "=={{int:license-header}}==\n";
1179111791
1179211792 // in the other implementations, category text follows immediately after license text. This helps
1179311793 // group categories together, maybe?
11794 - wikiText += deed.getLicenseWikiText() + _this.div.find( '.categoryInput' ).get(0).getWikiText();
 11794+ wikiText += deed.getLicenseWikiText() + _this.div.find( '.categoryInput' ).get(0).getWikiText() + "\n\n";
1179511795
1179611796
1179711797 return wikiText;
Index: branches/REL1_17/extensions/UploadWizard/resources/combined.min.js
@@ -11775,7 +11775,7 @@
1177611776
1177711777 wikiText+="=={{int:filedesc}}==\n";
1177811778
11779 -wikiText+='{{Information\n'+info+'}}\n';
 11779+wikiText+='{{Information\n'+info+'}}\n\n';
1178011780
1178111781
1178211782
@@ -11783,14 +11783,14 @@
1178411784 var otherInfoWikiText=$j(_this.otherInformationInput).val().trim();
1178511785 if(!mw.isEmpty(otherInfoWikiText)){
1178611786 wikiText+="=={{int:otherinfo}}==\n";
11787 -wikiText+=otherInfoWikiText;
 11787+wikiText+=otherInfoWikiText+"\n\n";
1178811788 }
1178911789
1179011790 wikiText+="=={{int:license-header}}==\n";
1179111791
1179211792
1179311793
11794 -wikiText+=deed.getLicenseWikiText()+_this.div.find('.categoryInput').get(0).getWikiText();
 11794+wikiText+=deed.getLicenseWikiText()+_this.div.find('.categoryInput').get(0).getWikiText()+"\n\n";
1179511795
1179611796
1179711797 return wikiText;
Index: branches/REL1_17/extensions/CentralAuth/SpecialGlobalUsers.php
@@ -31,7 +31,7 @@
3232 }
3333
3434 class GlobalUsersPager extends UsersPager {
35 - private $requestedGroup = false, $requestedUser;
 35+ protected $requestedGroup = false, $requestedUser;
3636
3737 function __construct() {
3838 parent::__construct();
Index: branches/REL1_17/extensions/FlaggedRevs/FlaggedRevision.php
@@ -313,16 +313,17 @@
314314 # Update flagged revisions table
315315 $dbw->replace( 'flaggedrevs', array( array( 'fr_page_id', 'fr_rev_id' ) ),
316316 $revRow, __METHOD__ );
317 - # Clear out any previous garbage.
318 - # We want to be able to use this for tracking...
 317+ # Clear out any previous garbage...
319318 $dbw->delete( 'flaggedtemplates',
320319 array( 'ft_rev_id' => $this->getRevId() ), __METHOD__ );
321 - $dbw->delete( 'flaggedimages',
322 - array( 'fi_rev_id' => $this->getRevId() ), __METHOD__ );
323 - # Update our versioning params
 320+ # ...and insert template version data
324321 if ( $tmpInsertRows ) {
325322 $dbw->insert( 'flaggedtemplates', $tmpInsertRows, __METHOD__, 'IGNORE' );
326323 }
 324+ # Clear out any previous garbage...
 325+ $dbw->delete( 'flaggedimages',
 326+ array( 'fi_rev_id' => $this->getRevId() ), __METHOD__ );
 327+ # ...and insert file version data
327328 if ( $fileInsertRows ) {
328329 $dbw->insert( 'flaggedimages', $fileInsertRows, __METHOD__, 'IGNORE' );
329330 }
Index: branches/REL1_17/phase3/maintenance/tests/phpunit/phpunit.php
@@ -20,9 +20,6 @@
2121 // Assume UTC for testing purposes
2222 $wgLocaltimezone = 'UTC';
2323
24 -// To prevent tests from failing with SQLite, we need to turn database caching off
25 -$wgCaches[CACHE_DB] = false;
26 -
2724 require_once( 'PHPUnit/Runner/Version.php' );
2825 if( version_compare( PHPUnit_Runner_Version::id(), '3.5.0', '>=' ) ) {
2926 # PHPUnit 3.5.0 introduced a nice autoloader based on class name
Index: branches/REL1_17/phase3/includes/upload/UploadFromUrl.php
@@ -33,19 +33,19 @@
3434
3535 /**
3636 * Entry point for API upload
37 - *
 37+ *
3838 * @param $name string
3939 * @param $url string
40 - * @param $async mixed Whether the download should be performed
 40+ * @param $async mixed Whether the download should be performed
4141 * asynchronous. False for synchronous, async or async-leavemessage for
4242 * asynchronous download.
4343 */
4444 public function initialize( $name, $url, $async = false ) {
4545 global $wgAllowAsyncCopyUploads;
46 -
 46+
4747 $this->mUrl = $url;
4848 $this->mAsync = $wgAllowAsyncCopyUploads ? $async : false;
49 -
 49+
5050 $tempPath = $this->mAsync ? null : $this->makeTemporaryFile();
5151 # File size and removeTempFile will be filled in later
5252 $this->initializePathInfo( $name, $tempPath, 0, false );
@@ -77,13 +77,13 @@
7878 && Http::isValidURI( $url )
7979 && $wgUser->isAllowed( 'upload_by_url' );
8080 }
81 -
8281
 82+
8383 public function fetchFile() {
8484 if ( !Http::isValidURI( $this->mUrl ) ) {
8585 return Status::newFatal( 'http-invalid-url' );
8686 }
87 -
 87+
8888 if ( !$this->mAsync ) {
8989 return $this->reallyFetchFile();
9090 }
@@ -91,7 +91,7 @@
9292 }
9393 /**
9494 * Create a new temporary file in the URL subdirectory of wfTempDir().
95 - *
 95+ *
9696 * @return string Path to the file
9797 */
9898 protected function makeTemporaryFile() {
@@ -99,8 +99,8 @@
100100 }
101101 /**
102102 * Save the result of a HTTP request to the temporary file
103 - *
104 - * @param $req MWHttpRequest
 103+ *
 104+ * @param $req MWHttpRequest
105105 * @return Status
106106 */
107107 private function saveTempFile( $req ) {
@@ -137,7 +137,7 @@
138138 }
139139
140140 /**
141 - * Wrapper around the parent function in order to defer verifying the
 141+ * Wrapper around the parent function in order to defer verifying the
142142 * upload until the file really has been fetched.
143143 */
144144 public function verifyUpload() {
@@ -158,7 +158,7 @@
159159 }
160160 return parent::checkWarnings();
161161 }
162 -
 162+
163163 /**
164164 * Wrapper around the parent function in order to defer checking protection
165165 * until we are sure that the file can actually be uploaded
@@ -169,7 +169,7 @@
170170 }
171171 return parent::verifyPermissions( $user );
172172 }
173 -
 173+
174174 /**
175175 * Wrapper around the parent function in order to defer uploading to the
176176 * job queue for asynchronous uploads
@@ -177,18 +177,18 @@
178178 public function performUpload( $comment, $pageText, $watch, $user ) {
179179 if ( $this->mAsync ) {
180180 $sessionKey = $this->insertJob( $comment, $pageText, $watch, $user );
181 -
 181+
182182 $status = new Status;
183183 $status->error( 'async', $sessionKey );
184184 return $status;
185185 }
186 -
 186+
187187 return parent::performUpload( $comment, $pageText, $watch, $user );
188188 }
189189
190 -
 190+
191191 protected function insertJob( $comment, $pageText, $watch, $user ) {
192 - $sessionKey = $this->getSessionKey();
 192+ $sessionKey = $this->stashSession();
193193 $job = new UploadFromUrlJob( $this->getTitle(), array(
194194 'url' => $this->mUrl,
195195 'comment' => $comment,
@@ -204,6 +204,6 @@
205205 $job->insert();
206206 return $sessionKey;
207207 }
208 -
209208
 209+
210210 }
Index: branches/REL1_17/phase3/includes/CategoryPage.php
@@ -162,9 +162,10 @@
163163 */
164164 function addSubcategoryObject( Category $cat, $sortkey, $pageLength ) {
165165 // Subcategory; strip the 'Category' namespace from the link text.
 166+ $title = $cat->getTitle();
166167 $this->children[] = $this->getSkin()->link(
167 - $cat->getTitle(),
168 - null,
 168+ $title,
 169+ $title->getText(),
169170 array(),
170171 array(),
171172 array( 'known', 'noclasses' )
Index: branches/REL1_17/phase3/includes/GlobalFunctions.php
@@ -305,7 +305,7 @@
306306 */
307307 function wfDebug( $text, $logonly = false ) {
308308 global $wgOut, $wgDebugLogFile, $wgDebugComments, $wgProfileOnly, $wgDebugRawPage;
309 - global $wgDebugLogPrefix, $wgShowDebug, $wgCommandLineMode, $wgDebugToCommandLine;
 309+ global $wgDebugLogPrefix, $wgShowDebug;
310310 static $recursion = 0;
311311
312312 static $cache = array(); // Cache of unoutputted messages
Property changes on: branches/REL1_17/phase3/includes/GlobalFunctions.php
___________________________________________________________________
Modified: svn:mergeinfo
313313 Merged /trunk/phase3/includes/GlobalFunctions.php:r77988,78012,78018,78043,78046,78071,78081,78083
Index: branches/REL1_17/phase3/includes/OutputPage.php
@@ -2458,7 +2458,7 @@
24592459 $action = $wgRequest->getVal( 'action', 'view' );
24602460 if( $this->mTitle && $this->mTitle->isJsSubpage() && $sk->userCanPreview( $action ) ) {
24612461 # XXX: additional security check/prompt?
2462 - $this->addInlineScript( $wgRequest->getText( 'wpTextbox1' ) );
 2462+ $scripts .= Html::inlineScript( "\n" . $wgRequest->getText( 'wpTextbox1' ) . "\n" ) . "\n";
24632463 } else {
24642464 $scripts .= $this->makeResourceLoaderLink(
24652465 $sk, array( 'user', 'user.options' ), 'scripts'
@@ -2588,15 +2588,19 @@
25892589 }
25902590 }
25912591
2592 - // Split the styles into two groups, not user (0) and user (1)
2593 - $styles = array( array(), array() );
 2592+ // Split the styles into three groups
 2593+ $styles = array( 'other' => array(), 'user' => array(), 'site' => array() );
25942594 $resourceLoader = $this->getResourceLoader();
25952595 foreach ( $this->getModuleStyles() as $name ) {
2596 - $styles[$resourceLoader->getModule( $name )->getGroup() === 'user' ? 1 : 0][] = $name;
 2596+ $group = $resourceLoader->getModule( $name )->getGroup();
 2597+ // Modules in groups named "other" or anything different than "user" or "site" will
 2598+ // be placed in the "other" group
 2599+ $styles[isset( $style[$group] ) ? $group : 'other'][] = $name;
25972600 }
25982601 // Add styles to tags, user modules last
2599 - $tags[] = $this->makeResourceLoaderLink( $sk, $styles[0], 'styles' );
2600 - $tags[] = $this->makeResourceLoaderLink( $sk, $styles[1], 'styles' );
 2602+ $tags[] = $this->makeResourceLoaderLink(
 2603+ $sk, array_merge( $styles['other'], $styles['site'], $styles['user'] ), 'styles'
 2604+ );
26012605 return implode( "\n", $tags );
26022606 }
26032607
Property changes on: branches/REL1_17/phase3/includes/OutputPage.php
___________________________________________________________________
Modified: svn:mergeinfo
26042608 Merged /trunk/phase3/includes/OutputPage.php:r78012,78018,78043,78046,78071,78081,78083
Index: branches/REL1_17/phase3/includes/installer/Installer.php
@@ -388,16 +388,13 @@
389389 return false;
390390 }
391391
392 - $this->showMessage( 'config-have-db', $wgLang->listToText( $goodNames ), count( $goodNames ) );
393 -
394392 // Check for FTS3 full-text search module
395393 $sqlite = $this->getDBInstaller( 'sqlite' );
396394 if ( $sqlite->isCompiled() ) {
397395 $db = new DatabaseSqliteStandalone( ':memory:' );
398 - $this->showMessage( $db->getFulltextSearchModule() == 'FTS3'
399 - ? 'config-have-fts3'
400 - : 'config-no-fts3'
401 - );
 396+ if( $db->getFulltextSearchModule() != 'FTS3' ) {
 397+ $this->showMessage( 'config-no-fts3' );
 398+ }
402399 }
403400 }
404401
@@ -492,7 +489,6 @@
493490 $this->showMessage( 'config-xml-bad' );
494491 return false;
495492 }
496 - $this->showMessage( 'config-xml-good' );
497493 }
498494
499495 /**
@@ -519,7 +515,6 @@
520516 $limit = ini_get( 'memory_limit' );
521517
522518 if ( !$limit || $limit == -1 ) {
523 - $this->showMessage( 'config-memory-none' );
524519 return true;
525520 }
526521
@@ -539,7 +534,7 @@
540535 $this->setVar( '_RaiseMemory', true );
541536 }
542537 } else {
543 - $this->showMessage( 'config-memory-ok', $limit );
 538+ return true;
544539 }
545540 }
546541
@@ -548,11 +543,9 @@
549544 */
550545 protected function envCheckCache() {
551546 $caches = array();
552 -
553547 foreach ( $this->objectCaches as $name => $function ) {
554548 if ( function_exists( $function ) ) {
555549 $caches[$name] = true;
556 - $this->showMessage( 'config-' . $name );
557550 }
558551 }
559552
@@ -573,7 +566,6 @@
574567 $diff3 = $this->locateExecutableInDefaultPaths( $names, $versionInfo );
575568
576569 if ( $diff3 ) {
577 - $this->showMessage( 'config-diff3-good', $diff3 );
578570 $this->setVar( 'wgDiff3', $diff3 );
579571 } else {
580572 $this->setVar( 'wgDiff3', false );
@@ -608,7 +600,6 @@
609601 $IP = dirname( dirname( dirname( __FILE__ ) ) );
610602
611603 $this->setVar( 'IP', $IP );
612 - $this->showMessage( 'config-dir', $IP );
613604
614605 // PHP_SELF isn't available sometimes, such as when PHP is CGI but
615606 // cgi.fix_pathinfo is disabled. In that case, fall back to SCRIPT_NAME
@@ -627,7 +618,6 @@
628619
629620 $uri = preg_replace( '{^(.*)/config.*$}', '$1', $path );
630621 $this->setVar( 'wgScriptPath', $uri );
631 - $this->showMessage( 'config-uri', $uri );
632622 }
633623
634624 /**
@@ -640,9 +630,7 @@
641631 } else {
642632 $ext = 'php';
643633 }
644 -
645634 $this->setVar( 'wgScriptExtension', ".$ext" );
646 - $this->showMessage( 'config-file-extension', $ext );
647635 }
648636
649637 /**
@@ -686,7 +674,6 @@
687675 # Try the current value of LANG.
688676 if ( isset( $candidatesByLocale[ getenv( 'LANG' ) ] ) ) {
689677 $this->setVar( 'wgShellLocale', getenv( 'LANG' ) );
690 - $this->showMessage( 'config-shell-locale', getenv( 'LANG' ) );
691678 return true;
692679 }
693680
@@ -695,7 +682,6 @@
696683 foreach ( $commonLocales as $commonLocale ) {
697684 if ( isset( $candidatesByLocale[$commonLocale] ) ) {
698685 $this->setVar( 'wgShellLocale', $commonLocale );
699 - $this->showMessage( 'config-shell-locale', $commonLocale );
700686 return true;
701687 }
702688 }
@@ -706,7 +692,6 @@
707693 if ( isset( $candidatesByLang[$wikiLang] ) ) {
708694 $m = reset( $candidatesByLang[$wikiLang] );
709695 $this->setVar( 'wgShellLocale', $m[0] );
710 - $this->showMessage( 'config-shell-locale', $m[0] );
711696 return true;
712697 }
713698
@@ -714,7 +699,6 @@
715700 if ( count( $candidatesByLocale ) ) {
716701 $m = reset( $candidatesByLocale );
717702 $this->setVar( 'wgShellLocale', $m[0] );
718 - $this->showMessage( 'config-shell-locale', $m[0] );
719703 return true;
720704 }
721705
@@ -733,7 +717,7 @@
734718 $safe = !$this->dirIsExecutable( $dir, $url );
735719
736720 if ( $safe ) {
737 - $this->showMessage( 'config-uploads-safe' );
 721+ return true;
738722 } else {
739723 $this->showMessage( 'config-uploads-not-safe', $dir );
740724 }
Index: branches/REL1_17/phase3/includes/installer/Installer.i18n.php
@@ -89,8 +89,6 @@
9090 If you are on shared hosting, ask your hosting provider to install a suitable database driver.
9191 If you compiled PHP yourself, reconfigure it with a database client enabled, for example using <code>./configure --with-mysql</code>.
9292 If you installed PHP from a Debian or Ubuntu package, then you also need install the php5-mysql module.',
93 - 'config-have-db' => 'Found database {{PLURAL:$2|driver|drivers}}: $1.',
94 - 'config-have-fts3' => 'SQLite is compiled with the [http://sqlite.org/fts3.html FTS3 module], search features will be available on this backend.',
9593 'config-no-fts3' => "'''Warning''': SQLite is compiled without the [http://sqlite.org/fts3.html FTS3 module], search features will be unavailable on this backend.",
9694 'config-register-globals' => "'''Warning: PHP's <code>[http://php.net/register_globals register_globals]</code> option is enabled.'''
9795 '''Disable it if you can.'''
@@ -109,7 +107,6 @@
110108 You cannot install or use MediaWiki unless this option is disabled.",
111109 'config-safe-mode' => "'''Warning:''' PHP's [http://www.php.net/features.safe-mode safe mode] is active.
112110 It may cause problems, particularly if using file uploads and <code>math</code> support.",
113 - 'config-xml-good' => 'Have XML / Latin1-UTF-8 conversion support.',
114111 'config-xml-bad' => "PHP's XML module is missing.
115112 MediaWiki requires functions in this module and will not work in this configuration.
116113 If you're running Mandrake, install the php-xml package.",
@@ -117,9 +114,6 @@
118115 MediaWiki requires the Perl-compatible regular expression functions to work.',
119116 'config-pcre-no-utf8' => "'''Fatal''': PHP's PCRE module seems to be compiled without PCRE_UTF8 support.
120117 MediaWiki requires UTF-8 support to function correctly.",
121 - 'config-memory-none' => 'PHP is configured with no <code>memory_limit</code>',
122 - 'config-memory-ok' => "PHP's <code>memory_limit</code> is $1.
123 -OK.",
124118 'config-memory-raised' => "PHP's <code>memory_limit</code> is $1, raised to $2.",
125119 'config-memory-bad' => "'''Warning:''' PHP's <code>memory_limit</code> is $1.
126120 This is probably too low.
@@ -130,7 +124,6 @@
131125 'config-wincache' => '[http://www.iis.net/download/WinCacheForPhp WinCache] is installed',
132126 'config-no-cache' => "'''Warning:''' Could not find [http://eaccelerator.sourceforge.net eAccelerator], [http://www.php.net/apc APC], [http://trac.lighttpd.net/xcache/ XCache] or [http://www.iis.net/download/WinCacheForPhp WinCache].
133127 Object caching is not enabled.",
134 - 'config-diff3-good' => 'Found GNU diff3: <code>$1</code>.',
135128 'config-diff3-bad' => 'GNU diff3 not found.',
136129 'config-imagemagick' => 'Found ImageMagick: <code>$1</code>.
137130 Image thumbnailing will be enabled if you enable uploads.',
@@ -138,13 +131,8 @@
139132 Image thumbnailing will be enabled if you enable uploads.',
140133 'config-no-scaling' => 'Could not find GD library or ImageMagick.
141134 Image thumbnailing will be disabled.',
142 - 'config-dir' => 'Installation directory: <code>$1</code>.',
143 - 'config-uri' => 'Script URI path: <code>$1</code>.',
144135 'config-no-uri' => "'''Error:''' Could not determine the current URI.
145136 Installation aborted.",
146 - 'config-file-extension' => 'Installing MediaWiki with <code>$1</code> file extensions.',
147 - 'config-shell-locale' => 'Detected shell locale "$1"',
148 - 'config-uploads-safe' => 'The default directory for uploads is safe from arbitrary scripts execution.',
149137 'config-uploads-not-safe' => "'''Warning:''' Your default directory for uploads <code>$1</code> is vulnerable to arbitrary scripts execution.
150138 Although MediaWiki checks all uploaded files for security threats, it is highly recommended to [http://www.mediawiki.org/wiki/Manual:Security#Upload_security close this security vulnerability] before enabling uploads.",
151139 'config-brokenlibxml' => 'Your system has a combination of PHP and libxml2 versions which is buggy and can cause hidden data corruption in MediaWiki and other web applications.
Index: branches/REL1_17/phase3/includes/DjVuImage.php
@@ -266,10 +266,7 @@
267267 | # Or page can be empty ; in this case, djvutxt dumps ()
268268 \(\s*()\)/sx
269269 EOR;
270 - $txt = preg_replace_callback( $reg,
271 - create_function('$matches', 'return \'<PAGE value="\'.htmlspecialchars($matches[1]).\'" />\';'),
272 - $txt );
273 -
 270+ $txt = preg_replace_callback( $reg, array( $this, 'pageTextCallback' ), $txt );
274271 $txt = "<DjVuTxt>\n<HEAD></HEAD>\n<BODY>\n" . $txt . "</BODY>\n</DjVuTxt>\n";
275272 $xml = preg_replace( "/<DjVuXML>/", "<mw-djvu><DjVuXML>", $xml );
276273 $xml = $xml . $txt. '</mw-djvu>' ;
@@ -278,6 +275,10 @@
279276 return $xml;
280277 }
281278
 279+ function pageTextCallback( $matches ) {
 280+ return '<PAGE value="' . htmlspecialchars( $matches[1] ) . '" />';
 281+ }
 282+
282283 /**
283284 * Hack to temporarily work around djvutoxml bug
284285 */
Index: branches/REL1_17/phase3/trackback.php
@@ -38,7 +38,7 @@
3939 public function __construct() {
4040 global $wgUseTrackbacks, $wgRequest;
4141
42 - if( !$wgUseTrackbacks && false )
 42+ if( !$wgUseTrackbacks )
4343 $this->XMLerror( "Trackbacks are disabled" );
4444
4545 $this->r = $wgRequest;
Property changes on: branches/REL1_17/phase3/trackback.php
___________________________________________________________________
Added: svn:mergeinfo
4646 Merged /branches/sqlite/trackback.php:r58211-58321
4747 Merged /trunk/phase3/trackback.php:r78007,78071
4848 Merged /branches/new-installer/phase3/trackback.php:r43664-66004
4949 Merged /branches/REL1_15/phase3/trackback.php:r51646
Index: branches/REL1_17/phase3/RELEASE-NOTES
@@ -466,6 +466,7 @@
467467 show up as (struck-out) bluelinks instead of redlinks on Special:WantedFiles
468468 * rebuildFileCache.php no longer creates inappropriate cache files for redirects
469469 * (bug 18372) $wgFileExtensions will now override $wgFileBlacklist
 470+* (bug 25512) Subcategory list should not include category prefix for members.
470471
471472 === API changes in 1.17 ===
472473 * (bug 22738) Allow filtering by action type on query=logevent.
Index: branches/REL1_17/phase3/resources/jquery/jquery.tipsy.js
@@ -1,202 +0,0 @@
2 -// tipsy, facebook style tooltips for jquery
3 -// version 1.0.0a
4 -// (c) 2008-2010 jason frame [jason@onehackoranother.com]
5 -// released under the MIT license
6 -
7 -(function($) {
8 -
9 - function Tipsy(element, options) {
10 - this.$element = $(element);
11 - this.options = options;
12 - this.enabled = true;
13 - this.fixTitle();
14 - }
15 -
16 - Tipsy.prototype = {
17 - show: function() {
18 - var title = this.getTitle();
19 - if (title && this.enabled) {
20 - var $tip = this.tip();
21 -
22 - $tip.find('.tipsy-inner')[this.options.html ? 'html' : 'text'](title);
23 - $tip[0].className = 'tipsy'; // reset classname in case of dynamic gravity
24 - $tip.remove().css({top: 0, left: 0, visibility: 'hidden', display: 'block'}).appendTo(document.body);
25 -
26 - var pos = $.extend({}, this.$element.offset(), {
27 - width: this.$element[0].offsetWidth,
28 - height: this.$element[0].offsetHeight
29 - });
30 -
31 - var actualWidth = $tip[0].offsetWidth, actualHeight = $tip[0].offsetHeight;
32 - var gravity = (typeof this.options.gravity == 'function')
33 - ? this.options.gravity.call(this.$element[0])
34 - : this.options.gravity;
35 -
36 - var tp;
37 - switch (gravity.charAt(0)) {
38 - case 'n':
39 - tp = {top: pos.top + pos.height + this.options.offset, left: pos.left + pos.width / 2 - actualWidth / 2};
40 - break;
41 - case 's':
42 - tp = {top: pos.top - actualHeight - this.options.offset, left: pos.left + pos.width / 2 - actualWidth / 2};
43 - break;
44 - case 'e':
45 - tp = {top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left - actualWidth - this.options.offset};
46 - break;
47 - case 'w':
48 - tp = {top: pos.top + pos.height / 2 - actualHeight / 2, left: pos.left + pos.width + this.options.offset};
49 - break;
50 - }
51 -
52 - if (gravity.length == 2) {
53 - if (gravity.charAt(1) == 'w') {
54 - tp.left = pos.left + pos.width / 2 - 15;
55 - } else {
56 - tp.left = pos.left + pos.width / 2 - actualWidth + 15;
57 - }
58 - }
59 -
60 - $tip.css(tp).addClass('tipsy-' + gravity);
61 -
62 - if (this.options.fade) {
63 - $tip.stop().css({opacity: 0, display: 'block', visibility: 'visible'}).animate({opacity: this.options.opacity});
64 - } else {
65 - $tip.css({visibility: 'visible', opacity: this.options.opacity});
66 - }
67 - }
68 - },
69 -
70 - hide: function() {
71 - if (this.options.fade) {
72 - this.tip().stop().fadeOut(function() { $(this).remove(); });
73 - } else {
74 - this.tip().remove();
75 - }
76 - },
77 -
78 - fixTitle: function() {
79 - var $e = this.$element;
80 - if ($e.attr('title') || typeof($e.attr('original-title')) != 'string') {
81 - $e.attr('original-title', $e.attr('title') || '').removeAttr('title');
82 - }
83 - },
84 -
85 - getTitle: function() {
86 - var title, $e = this.$element, o = this.options;
87 - this.fixTitle();
88 - var title, o = this.options;
89 - if (typeof o.title == 'string') {
90 - title = $e.attr(o.title == 'title' ? 'original-title' : o.title);
91 - } else if (typeof o.title == 'function') {
92 - title = o.title.call($e[0]);
93 - }
94 - title = ('' + title).replace(/(^\s*|\s*$)/, "");
95 - return title || o.fallback;
96 - },
97 -
98 - tip: function() {
99 - if (!this.$tip) {
100 - this.$tip = $('<div class="tipsy"></div>').html('<div class="tipsy-arrow"></div><div class="tipsy-inner"></div>');
101 - }
102 - return this.$tip;
103 - },
104 -
105 - validate: function() {
106 - if (!this.$element[0].parentNode) {
107 - this.hide();
108 - this.$element = null;
109 - this.options = null;
110 - }
111 - },
112 -
113 - enable: function() { this.enabled = true; },
114 - disable: function() { this.enabled = false; },
115 - toggleEnabled: function() { this.enabled = !this.enabled; }
116 - };
117 -
118 - $.fn.tipsy = function(options) {
119 -
120 - if (options === true) {
121 - return this.data('tipsy');
122 - } else if (typeof options == 'string') {
123 - var tipsy = this.data('tipsy');
124 - if (tipsy) tipsy[options]();
125 - return this;
126 - }
127 -
128 - options = $.extend({}, $.fn.tipsy.defaults, options);
129 -
130 - function get(ele) {
131 - var tipsy = $.data(ele, 'tipsy');
132 - if (!tipsy) {
133 - tipsy = new Tipsy(ele, $.fn.tipsy.elementOptions(ele, options));
134 - $.data(ele, 'tipsy', tipsy);
135 - }
136 - return tipsy;
137 - }
138 -
139 - function enter() {
140 - var tipsy = get(this);
141 - tipsy.hoverState = 'in';
142 - if (options.delayIn == 0) {
143 - tipsy.show();
144 - } else {
145 - tipsy.fixTitle();
146 - setTimeout(function() { if (tipsy.hoverState == 'in') tipsy.show(); }, options.delayIn);
147 - }
148 - };
149 -
150 - function leave() {
151 - var tipsy = get(this);
152 - tipsy.hoverState = 'out';
153 - if (options.delayOut == 0) {
154 - tipsy.hide();
155 - } else {
156 - setTimeout(function() { if (tipsy.hoverState == 'out') tipsy.hide(); }, options.delayOut);
157 - }
158 - };
159 -
160 - if (!options.live) this.each(function() { get(this); });
161 -
162 - if (options.trigger != 'manual') {
163 - var binder = options.live ? 'live' : 'bind',
164 - eventIn = options.trigger == 'hover' ? 'mouseenter' : 'focus',
165 - eventOut = options.trigger == 'hover' ? 'mouseleave' : 'blur';
166 - this[binder](eventIn, enter)[binder](eventOut, leave);
167 - }
168 -
169 - return this;
170 -
171 - };
172 -
173 - $.fn.tipsy.defaults = {
174 - delayIn: 0,
175 - delayOut: 0,
176 - fade: false,
177 - fallback: '',
178 - gravity: 'n',
179 - html: false,
180 - live: false,
181 - offset: 0,
182 - opacity: 0.8,
183 - title: 'title',
184 - trigger: 'hover'
185 - };
186 -
187 - // Overwrite this method to provide options on a per-element basis.
188 - // For example, you could store the gravity in a 'tipsy-gravity' attribute:
189 - // return $.extend({}, options, {gravity: $(ele).attr('tipsy-gravity') || 'n' });
190 - // (remember - do not modify 'options' in place!)
191 - $.fn.tipsy.elementOptions = function(ele, options) {
192 - return $.metadata ? $.extend({}, options, $(ele).metadata()) : options;
193 - };
194 -
195 - $.fn.tipsy.autoNS = function() {
196 - return $(this).offset().top > ($(document).scrollTop() + $(window).height() / 2) ? 's' : 'n';
197 - };
198 -
199 - $.fn.tipsy.autoWE = function() {
200 - return $(this).offset().left > ($(document).scrollLeft() + $(window).width() / 2) ? 'e' : 'w';
201 - };
202 -
203 -})(jQuery);
Index: branches/REL1_17/phase3/resources/jquery.ui/themes/vector/jquery.ui.dialog.css
@@ -8,7 +8,7 @@
99 .ui-dialog .ui-dialog-titlebar-close:hover, .ui-dialog .ui-dialog-titlebar-close:focus { padding: 0; }
1010 .ui-dialog .ui-dialog-content { border: 0; padding: .5em 1em; background: none; overflow: auto; zoom: 1; }
1111 .ui-dialog .ui-dialog-buttonpane { text-align: left; border-width: 1px 0 0 0; background-image: none; margin: .5em 0 0 0; padding: .3em 1em .5em .4em; }
12 -.ui-dialog .ui-dialog-buttonpane button { float: right; margin: .5em .4em .5em 0; cursor: pointer; padding: .2em .6em .3em .6em; line-height: 1.4em; width:auto; overflow:visible; }
 12+.ui-dialog .ui-dialog-buttonpane button { float: right; }
1313 .ui-dialog .ui-resizable-se { width: 14px; height: 14px; right: 3px; bottom: 3px; }
1414 .ui-draggable .ui-dialog-titlebar { cursor: move; }
1515 /* Customizations */
@@ -22,32 +22,6 @@
2323 body .ui-dialog .ui-dialog-titlebar {
2424 padding: 0.9em 1.4em 0.6em !important;
2525 }
26 -body .ui-dialog .ui-dialog-buttonpane button {
27 - -moz-border-radius: 4px;
28 - -webkit-border-radius: 4px;
29 - padding: 0.2em 0.6em 0.15em !important;
30 - margin: 0.5em 0 0.5em 0.4em !important;
31 - border: 1px solid #a6a6a6 !important;
32 - background: #f2f2f2 url(images/button-off.png) repeat-x scroll 50% 100% !important;
33 -}
34 -body .ui-dialog .ui-dialog-buttonpane button:hover {
35 - border-color: #6e7273;
36 - background: #e1e1e1 url(images/button-over.png) repeat-x scroll 50% 100% !important;
37 -}
38 -body .ui-dialog .ui-dialog-buttonpane button:active,
39 -body .ui-dialog .ui-dialog-buttonpane button:focus {
40 - border-color: #707271;
41 - background: #bfbfbf url(images/button-down.png) repeat-x scroll 50% 100% !important;
42 -}
43 -body .ui-dialog .ui-dialog-buttonpane button.disabled {
44 - color: #7f7f7f;
45 - border-color: #cccccc;
46 - background: #f2f2f2 url(images/button-disabled.png) repeat-x scroll 50% 100% !important;
47 -}
48 -/* Disables the annoying dashed border Firefox puts on active buttons */
49 -body .ui-dialog .ui-dialog-buttonpane button::-moz-focus-inner {
50 - border: 0;
51 -}
5226 body .ui-dialog .ui-widget-header {
5327 background: #f0f0f0 url(images/titlebar-fade.png) repeat-x scroll 50% 100% !important;
5428 }
Index: branches/REL1_17/phase3/resources/jquery.ui/themes/vector/jquery.ui.button.css
@@ -29,7 +29,35 @@
3030 /* workarounds */
3131 button.ui-button::-moz-focus-inner { border: 0; padding: 0; } /* reset extra padding in Firefox */
3232
 33+body button.ui-button {
 34+ -moz-border-radius: 4px;
 35+ -webkit-border-radius: 4px;
 36+ padding: 0.2em 0.6em 0.15em !important;
 37+ margin: 0.5em 0 0.5em 0.4em !important;
 38+ border: 1px solid #a6a6a6 !important;
 39+ background: #f2f2f2 url(images/button-off.png) repeat-x scroll 50% 100% !important;
 40+ cursor: pointer;
 41+ font-size: 1em;
 42+ line-height: 1.4em;
 43+ width: auto;
 44+ overflow: visible;
 45+}
 46+body button.ui-button:hover {
 47+ border-color: #6e7273;
 48+ background: #e1e1e1 url(images/button-over.png) repeat-x scroll 50% 100% !important;
 49+}
 50+body button.ui-button:active,
 51+body button.ui-button:focus {
 52+ border-color: #707271;
 53+ background: #bfbfbf url(images/button-down.png) repeat-x scroll 50% 100% !important;
 54+}
 55+body button.ui-button.disabled {
 56+ color: #7f7f7f;
 57+ border-color: #cccccc;
 58+ background: #f2f2f2 url(images/button-disabled.png) repeat-x scroll 50% 100% !important;
 59+}
 60+/* Disables the annoying dashed border Firefox puts on active buttons */
 61+body button.ui-button::-moz-focus-inner {
 62+ border: 0;
 63+}
3364
34 -
35 -
36 -

Past revisions this follows-up on

RevisionCommit summaryAuthorDate
r77988Follow up r77884.platonides16:26, 7 December 2010
r77999Remove various "success" messages from Welcome screen on installer, no need t...demon18:29, 7 December 2010
r78006Logic error from r77999demon20:03, 7 December 2010
r78007Per CR, fix debugging code from r70835demon20:13, 7 December 2010
r78009Remove the $wgCaches[CACHE_DB] = false; line added in r74552....platonides20:40, 7 December 2010
r78012Typofix r77999demon21:08, 7 December 2010
r78018Improves on r77693 by ensuring site styles are loaded just before user styles.tparscal21:45, 7 December 2010
r78022Unbreak SpecialGlobalUsers.php by changing visibility of the class members.vasilievvv22:16, 7 December 2010
r78046Fix for r69139: create_function() is not allowed.tstarling05:57, 8 December 2010
r78052Tweak delete/insert query order to help with bug 26224aaron07:42, 8 December 2010
r78070Recombine resources for r77816catrope15:27, 8 December 2010
r78071(bug 25512) Make it so that categories listed in the subcategory section of a...bawolff16:01, 8 December 2010
r78081addInlineScript() won't work since the content of $mScripts is added to $scri...ialex17:53, 8 December 2010
r78083re r75906 — replace the removed getSessionKey() with stashSession()mah18:59, 8 December 2010
r78085Removing unused plugin filetparscal19:14, 8 December 2010
r78088Fix syntax error from r77928reedy19:20, 8 December 2010
r78089Moved button styles from dialog specific areas to button specific areas to ma...tparscal19:33, 8 December 2010

Status & tagging log