Performance improvements to doQuotes(), since it is a hot function.
Co-authored-by: Tyler Anthony Romeo <tylerromeo@gmail.com>
Change-Id: If78d4372a2acd78d58b020385da400978716cbf5
PHP's __call magic method can't handle functions with reference
parameters correctly,[1] which means that we need to manually unstub
StubObjects before calling such a method. Or you could use call-time
pass by reference with call_user_func_array, which is rather backwards
and verbose.
This change adds a convenience function to do this, and applies it to
the two calls which brought it to my attention.
[1]: https://bugs.php.net/bug.php?id=40694,
https://bugs.php.net/bug.php?id=62455
Change-Id: I74a0c04bf358e164f753b82fbefbd6205d9b2451
Use the srbackend parameter if it's valid.
If it's not, use $wgSearchType if it's not null.
Finally, fall back to the search type of the database.
Bug: 53982
Change-Id: I3605cb4add270543aa20afb037401b2dfbe462f0
The downside to inline-block is that you don't clear other inline
elements. Although inline elements surrounding the ToC are rare, they
are common enough that this introduced some problems on English
Wikipedia.
Instead, let's just display as table. This is a block element and has
all the boxmodel behavior that we want (that of a table, an intrinsic
wide block element). It's not the nicest perhaps, but it works in all
modern browsers without known problems as far as I'm aware.
We still fallback to inline mode on browsers that don't properly
support display:table.
Followup to: I4ecd0659d1f955a9b593d281a3fef0a81c218a52
Bug: 658
Change-Id: Ib8e2801f9a143de370589728aad01926906ffae0
This seems more convenient than having the space key
do nothing as it does right now.
Furthermore this is more consistent with the various
other collapsible things we have around than to just
scroll the page on a space keypress.
Bug: 53797
Change-Id: If9292ef6a8fd82b097c597dc166e38c8ca31f4ff
portal-url ("Community portal"), currentevents-url ("Current events")
and helppage ("Help") lead to empty pages in a fresh MediaWiki install,
when most projects won't need these pages ever. Removing the
corresponding lines.
Bug 53862
Change-Id: Icb0e1b91e40bd682629f8a6f7291dbf8588b586b
Make API action=upload return normalized file name on warning
"exists-normalized" instead of filename to be uploaded to.
This enables humans to see which file the current upload conflicts
with.
There is no point in returning the filename the upload should go to
because the client that makes the request is usually aware of this.
Bug: 52699
Change-Id: I898b7f234d43eb1e524952f6de80e401a8c96671
Disambiguation related functions have been re-implemented in the
Disambiguator extension.
Bug: 35981
Change-Id: I4afa30bf2677c6541ef355013f8eaef46abfbe03
Dependency: I41637ea43a9e5000bcb8a782441ce36f1068881f
Corrects inconsistent return value for number of pages in a
category when language variants are in use.
Change-Id: I27668ba348c45bc34b264f8771e91e58a9920552
* There is no label inside div#simpleSearch.
* Inside div#simpleSearch, input and input#searchInput are the
same in practice (there is a <input type=submit>, but it is hidden).
Change-Id: I1d9657a5ab608d1a54314dd7c96144af96c53d59
Basically implementing what Brion suggested on wikitech
This allows for injecting dependencies while still only loading the actual class when needed.
Simple example:
$wgActions['epundo'] = function( Page $page, IContextSource $context = null ) use ( $differ ) {
$undoAction = new \EducationProgram\UndoAction( $page, $context );
$undoAction->setDiffer( $differ );
return $undoAction;
};
Change-Id: I6c0f4022f1df1ebaf9cd1a5fe4bd362d0ecc0d62
Also removed some unnecessary ones. I think I've caught them all.
The spaceless version already appears in core ~300 times (after
accounting for false positives when grepping). Some consistency would
be nice.
Change-Id: I607655b5f4366e66dc78730d5fd2f57ed8776cae