Commit graph

81 commits

Author SHA1 Message Date
Brion Vibber
3a6ac5a3c3 Revert r20769: we don't use PHPDocumentor anymore, we use doxygen.
If making mass changes to tweak to its preferences, probably better to do it for the tool we actually generate docs with. :)
2007-03-28 14:16:43 +00:00
Nick Jenkins
5fef2333d4 PHPDocumentor [http://en.wikipedia.org/wiki/PhpDocumentor] documentation tweaking stuff.
Minor doc tweaks to prevent some PHPDocumentor warnings or errors when run on the includes/ directory. PHPDocumentor uses a syntax very similar to javadoc - mostly we already use this, but there were a few scattered places that were adjusted to make them consistent with the rest of the code. In practical terms, these changes were made:
* @url becomes @link
* @fixme becomes @todo
* HTML tags in descriptions must be closed / balanced.
* @bug was removed (where the bug was long fixed), or changed into a @todo (in the few situations where the bug was still pending)
* @obsolete becomes @deprecated
* Things like "/**@{{" and "/**@}}*/" which cause "unknown tag" warnings were removed
* @access must be a valid access level.
* @desc tag not needed, removed.
* Doesn't seem to like @licence, will accept @license however.
* Use full comment block notation in a few places (i.e. open block with "/**", start each line with " *", and end block with " */")

Then additional to this, to get some class docs associated with their respective classes:
* Moved some docs to right above those classes (deleting blank lines, or moving descriptions from the file headers)
* Marked some classes without docs as "@todo document"
* (done up to "class MIMEsearchPage" on the "classtrees_MediaWiki.html" page for the includes/ directory)
2007-03-28 08:53:02 +00:00
Rotem Liss
930a4da4ce Use the expanded text (e.g. anonymous users only, account creation disabled instead of anononly,nocreate) in the block log items of the recent changes (i.e. don't check for the variable translate when translating the second parameter - it was a workaround for the block expiry to prevent ugly HTML from appearing, it is not needed for the block flags). 2007-03-21 17:04:01 +00:00
Brion Vibber
9150412fe7 For now revert the rev_deleted branch merge; don't want trunk to get too far gone before changes are reviewed!
Reverted: 20511, 20510, 20507, 20474, 20461, 20460, 20457, 20448, 20446
2007-03-16 16:01:07 +00:00
Aaron Schulz
2448539ad9 *Merge in phase3_rev_deleted/includes 2007-03-14 15:50:06 +00:00
Nick Jenkins
f88c771756 The war on redundant ampersand usage!
* Convert "$dbw =& wfGetDB( DB_MASTER );" --> "$dbw = wfGetDB( DB_MASTER );"
* convert "$skin =& $wgUser->getSkin();" --> "$skin = $wgUser->getSkin();"

For the time being have not changed the function definitions of wfGetDB() or User::getSkin() [i.e. they are still both return-by-ref], so as to ensure the interface does not change for extensions [some of which may still be trying to run on PHP4 environments]. However presumably at some point this can be changed too.

Also includes tiny tweak to newlines in parserTests - will show 1 rather than 2 newlines between the "Reading tests from" strings when in quiet mode.
2007-01-22 23:50:42 +00:00
Antoine Musso
c771fc9c96 Use Doxygen @addtogroup instead of phpdoc @package && @subpackage 2007-01-20 15:09:52 +00:00
Antoine Musso
b144fcb85d Rename constructors to __constructor 2007-01-20 13:34:31 +00:00
Rob Church
c16298f2d2 * (bug 8621) Log revisions marked as patrolled
* Uses normal logging framework, but
** doesn't duplicate the log in recentchanges ;)
** uses a cleaner method to override LogPage::actionText() and do all the formatting
* Introduces PatrolLog::record()
2007-01-16 17:05:30 +00:00
Nick Jenkins
784e69d028 For the "includes/" directory:
* removing unused local vars
* removing used global declarations
* adding FIXMEs against extract() calls and lines that seem to be using uninitialized variables
* adding some array() declarations.
2007-01-12 10:03:51 +00:00
Rob Church
95bf9cee9a * (bug 6638) List block flags in block log entries
* New log parameter value for blocks
* LogPage::formatBlockFlag() and LogPage::formatBlockFlags() introduced [this should all be subclassed better]
* Support formatted lists of block flags in block log entries, where these are available [new blocks only]
2007-01-09 01:54:52 +00:00
Nick Jenkins
74ea267553 Prevent the following strict-standards warnings - i.e. when running with error_logging(E_ALL | E_STRICT); - which seems to disable the yucky "@" operator, as well as maxing out the pedantry of warnings. Nothing major found, just nice to be as explicit and as forward-compatible as possible.
* Strict Standards: Undefined index: switch in includes/Parser.php on line 3849
* Strict Standards: Undefined index: ref in includes/Parser.php on line 3818
* Strict Standards: Non-static method OutputPage::setEncodings() should not be called statically in index.php on line 11
* Strict Standards: Only variables should be assigned by reference in includes/Skin.php on line 888
* Strict Standards: Non-static method Title::newFromURL() should not be called statically in includes/SpecialContributions.php on line 178
* Strict Standards: Only variables should be assigned by reference in includes/GlobalFunctions.php on line 2054
* Strict Standards: Undefined index:  contributions-summary in languages/Language.php on line 764
* Strict Standards: Undefined index:  trackbackhtml in skins/MonoBook.php on line 86
* Strict Standards: Undefined index:  blockip in skins/MonoBook.php on line 204
* Strict Standards: Undefined index:  tagline in skins/MonoBook.php on line 261
* Strict Standards: Undefined index: uselang in includes/SkinTemplate.php on line 1159
* Strict Standards: Non-static method CoreParserFunctions::plural() cannot be called statically in includes/Parser.php on line 2902
* Strict Standards: Undefined offset:  0 in includes/SkinTemplate.php on line 196
* Strict Standards: Undefined index:  USE INDEX in includes/Database.php on line 1015
* Strict Standards: Undefined index:  image_tests in includes/Parser.php on line 3488
* Strict Standards: Undefined offset:  0 in includes/Parser.php on line 3507
* Strict Standards: Non-static method ChangesList::newFromUser() should not be called statically in includes/SpecialWatchlist.php on line 361
* Strict Standards: Non-static method RecentChange::newFromCurRow() should not be called statically in includes/SpecialWatchlist.php on line 367
* Strict Standards: is_a(): Deprecated. Please use the instanceof operator in includes/Exception.php on line 168
* Strict Standards: Non-static method LogPage::logName() should not be called statically in includes/SpecialContributions.php on line 325
* Strict Standards: ob_end_flush(): failed to delete and flush buffer. No buffer to delete or flush. in maintenance/commandLine.inc on line 191
* Strict Standards: Undefined index:  meatball in languages/Language.php on line 234
* Strict Standards: rmdir(/tmp/mwParser-2108164586-images/thumb): Directory not empty in maintenance/parserTests.inc on line 605
* Cleaning out some new temp files left over by parserTests (there were one or two straggler dirs/files that would persist after the test run ended, due to new tests being added over time)
* Strict Standards: Non-static method CoreParserFunctions::special() cannot be called statically in includes/Parser.php on line 2902
* Strict Standards: Declaration of ListUsersPage::preprocessResults() should be compatible with that of QueryPage::preprocessResults() in includes/SpecialListusers.php on line 38
* Strict Standards: Only variables should be passed by reference in includes/SpecialBlockip.php on line 175
* Strict Standards: Skin::include_once(skins/Standard.deps.php) [<a href='function.include-once'>function.include-once</a>]: failed to open stream: No such file or directory in includes/Skin.php on line 121
* Strict Standards: Declaration of ApiMain::getResult() should be compatible with that of ApiBase::getResult() in includes/api/ApiMain.php on line 35
* Strict Standards: is_a(): Deprecated. Please use the instanceof operator in includes/WikiError.php on line 63
* Strict Standards: Non-static method WikiError::isError() should not be called statically in includes/SpecialImport.php on line 64
* Strict Standards: Non-static method ImportStreamSource::newFromInterwiki() should not be called statically in includes/SpecialImport.php on line 58<b
* Strict Standards: Only variables should be assigned by reference in includes/SpecialUndelete.php on line 501
* Strict Standards: Non-static method Image::newFromName() should not be called statically in thumb.php on line 56
* Strict Standards: Non-static method CoreParserFunctions::numberoffiles() cannot be called statically in includes/Parser.php on line 2902
* Strict Standards: Non-static method CoreParserFunctions::statisticsFunction() should not be called statically in includes/CoreParserFunctions.php on line 139
* Strict Standards: Non-static method CoreParserFunctions::isRaw() should not be called statically in includes/CoreParserFunctions.php on line 128
* Strict Standards: Non-static method CoreParserFunctions::grammar() cannot be called statically in includes/Parser.php on line 2902
* Strict Standards: Undefined offset:  1 in includes/SpecialMIMEsearch.php on line 130
* Strict Standards: Undefined index:  recentchangeslinked in skins/MonoBook.php on line 184
* Strict Standards: Declaration of DumpNotalkFilter::pass() should be compatible with that of DumpFilter::pass() in includes/Export.php on line 612
* Strict Standards: Declaration of DumpNamespaceFilter::pass() should be compatible with that of DumpFilter::pass() in includes/Export.php on line 665
* Strict Standards: Non-static method ImportStreamSource::newFromUpload() should not be called statically in includes/SpecialImport.php on line 46
* Strict Standards: Undefined offset:  5 in includes/Sanitizer.php on line 396
* Strict Standards: Undefined index:  wikidbUserName in includes/SpecialUserlogin.php on line 562
* Strict Standards: Only variables should be assigned by reference in includes/api/ApiQueryBase.php on line 95
* Strict Standards: Only variables should be assigned by reference in includes/api/ApiQueryBase.php on line 116
* Strict Standards: Only variables should be assigned by reference in includes/api/ApiQueryWatchlist.php on line 128
* Strict Standards: Undefined property:  stdClass::$rc_id in includes/api/ApiQueryBase.php on line 131
* Strict Standards: Undefined property:  stdClass::$rc_last_oldid in includes/api/ApiQueryBase.php on line 164
* Strict Standards: Undefined property:  stdClass::$rc_moved_to_ns in includes/api/ApiQueryBase.php on line 285
* Strict Standards: Undefined property:  stdClass::$rc_patrolled in includes/api/ApiQueryBase.php on line 176
* Strict Standards: Undefined index:  comment in includes/api/ApiFeedWatchlist.php on line 85
* Strict Standards: Undefined offset:  0 in includes/Skin.php on line 302
* Strict Standards: Non-static method User::SetupSession() should not be called statically in includes/SpecialUserlogin.php on line 15

... There are certain to be other things too, so this is not intended to be comprehensive, rather the above just stops most of the notifications I observed.
2006-11-29 05:45:03 +00:00
Tim Starling
36ed0cd96c Reverting 17479/17480, breaks subclassing of Linker methods by skins. See my comment on bug 7405. 2006-11-08 07:12:03 +00:00
Nick Jenkins
fa239349f2 * (bug 7405) Make Linker methods static. Patch by Dan Li. 2006-11-08 05:21:15 +00:00
Tim Starling
a3b490d2c4 * Made special page names case-insensitive and localisable. Care has been taken to maintain backwards compatibility.
* Used special page subpages in a few more places, instead of query parameters
2006-10-30 06:25:31 +00:00
Tim Starling
0256e2c648 Removed forced call-by-reference from LogPage::addEntry(), causes errors in some PHP versions 2006-07-14 04:13:49 +00:00
Rotem Liss
58afa56f4a Rights log changes:
* Adding "(none)" notice also if the third parameter (new groups) is empty (when desysoping someone, for example).
* Adding the "(none)" notice also in the recent changes.
* Adding the "(none)" notice only if the action is "rights/rights", to prevent future potential incompatibility, if we add other log actions in "rights" log, or if an extension does so.
* First checking if the parameter is null before checking if it's empty, to prevent an ugly notice appears when using Makesysop (apparently not in Wikimedia servers, I think notices are disabled there).
2006-06-20 09:09:20 +00:00
Domas Mituzas
b08f2b4100 AutoLoad RecentChange 2006-06-06 11:44:18 +00:00
Brion Vibber
0a26267688 Revert to r14512; domas introduced massive breakage with incomplete experimental changes. They will be recommitted when they work. :) 2006-06-01 08:19:02 +00:00
Domas Mituzas
bda0b8e104 Use AutoLoader to load classes:
* remove require_once() throughout whole code, yet left in few places
* move global functions in HttpUtils, ProxyTools, Credits to class methods
* php5 only: __autoload() now used, combined with class->file map and require()
* move initialization of $wgValidSkinNames to Skin::getSkinNames()
* few more changes that will surely break stuff.
2006-06-01 07:22:49 +00:00
Brion Vibber
2fb7f4fdb2 To simplify the lives of extension developers, the logging type arrays can now be appended to directly by an extension setup function. It is no longer necessary to write four separate functions just to add a custom log type.
The old hooks for this are retained for backwards compatibility, but are deprecated.
2006-05-25 07:37:20 +00:00
Antoine Musso
7ebdb6de89 Revert to r14165 . Did too many changes, didnt even run parserTests (i am bad) 2006-05-11 22:40:38 +00:00
Antoine Musso
c3c2084ee2 Some more PHP5 stuff 2006-05-11 20:24:28 +00:00
Antoine Musso
bc14eb8045 Replacing var keyword with private / public as we now require PHP5. 2006-05-11 19:10:41 +00:00
Antoine Musso
473cd5cbcc unused variables as per #3692 2006-05-01 10:53:59 +00:00
Rob Church
287025787f * (bug 5593) Change "bureaucrat log" to "rights log"
* Show a boilerplate "(none)" in place of a blank within the log action text for user rights
2006-04-30 22:36:52 +00:00
Anders Wegge Jakobsen
ad8e5c9cce Fix for bug 5592 2006-04-18 18:05:13 +00:00
Rob Church
6cfd52b003 (Forgot to remove debugging line) 2006-04-15 15:30:17 +00:00
Rob Church
9bb397bd3a *(bug 5426) Lowercase treatment of titles in rights log leads to broken links on Special:Log -- force title text to inital-uppercase when showing rights log text. Root of the problem lies with the extension in use on Wikimedia sites, however; will poke. 2006-04-15 15:18:33 +00:00
Rob Church
c527accb75 (bug 5458) Fix double-URL encoding in block log link in contribs and contribs link in block log 2006-04-05 16:14:08 +00:00
Brion Vibber
f2c29baf9f Update the FSF's address in all these GPL stub headers 2006-04-05 07:43:17 +00:00
Brion Vibber
103be1dda1 * Further work on rev_deleted; changed to a bitfield with several data-hiding
options. Not yet ready for production use; Special:Revisiondelete is
  incomplete, and the flags are not preserved across page deletion/undeletion.
  To try it; add the 'deleterevision' permission to a privileged group.
Also split some functions from GlobalFunctions to XmlFunctions.php, added
some convenience functions for building form controls, some more Linker
conveniences for formatting various types of standard link clusters.
2006-03-16 19:04:25 +00:00
Lupin
c7408b9223 trailing whitespace removal 2006-03-11 17:13:49 +00:00
Tim Starling
8ae723cf37 better IRC lines for log entries 2006-03-06 13:51:58 +00:00
Brion Vibber
bb7fd21511 * Unknown log types no longer throw notices everywhere in RecentChanges
This has been driving me nuts when disabling extensions with custom log types.
2006-02-14 21:24:48 +00:00
Rob Church
7f01915163 Grrr...remove duplicate $, thanks Niklas 2006-02-05 22:59:53 +00:00
Rob Church
46c780b136 Fix broken contribs link in block log 2006-02-05 22:54:12 +00:00
Rob Church
12683a093e Clean up code in, and add contributions link to block log items 2006-01-29 23:24:01 +00:00
Brion Vibber
26cc539cac * Skip loading of RecentChange.php except where needed
Moved constants to Define.php; removed unneeded includes until use of RecentChange:: in Article, Log, CheckUser
2006-01-09 21:09:33 +00:00
Ævar Arnfjörð Bjarmason
a26d5a49d7 * s~\t+$~~ 2006-01-07 13:31:29 +00:00
Rob Church
93371357d4 * (bug 4359) red [[user:#id]] links generated in [[special:Log]] 2005-12-30 23:16:42 +00:00
Ævar Arnfjörð Bjarmason
ac558e6933 * Added a TODO comment 2005-10-20 20:03:08 +00:00
Ævar Arnfjörð Bjarmason
b09caa9d1a * Removed function validActions(), no longer used by anything
* Added a hook to isLogType() to be used by Newuserlog and Renameuser
* FIXME comment
2005-09-30 15:03:48 +00:00
Ævar Arnfjörð Bjarmason
d0f2e190e3 * Documentation
* Whitespace
* Added the setting of $updateRecentChanges to the constructor
2005-09-09 19:26:56 +00:00
Niklas Laxström
9d64c3e2e7 Don't mess recent changes 2005-08-27 18:50:51 +00:00
Niklas Laxström
73a2aea77b +* Experimental feature to allow translation of block expiry times 2005-08-27 16:35:10 +00:00
River Tarnell
b817c0c15f merge ORACLE_WORK. sorry, this may break some parts of MySQL, i did not test extensively. 2005-08-02 13:35:19 +00:00
Ævar Arnfjörð Bjarmason
fae689663f * (bug 2774) Add three new $wgHooks to LogPage which enable extensions to add
their own logtypes, see extensions/Renameuser/SpecialRenameuser.php for an
  example of this.
2005-07-22 18:55:58 +00:00
Ævar Arnfjörð Bjarmason
cf59db8b61 * Not showing " : " in recentchanges if the rcComment is empty
* Documentation
2005-07-07 14:10:00 +00:00
Ævar Arnfjörð Bjarmason
03220d42c9 * Documented the constructor
* Fixed a logic error in actionText(), extensions can now write to the log
  using an empty action string without warnings.
* Formatting
2005-07-07 13:44:33 +00:00