Add better error message for files which exceeds $wgMaxImageArea
authorumherirrender <umherirrender_de.wp@web.de>
Wed, 25 Jun 2014 19:30:08 +0000 (21:30 +0200)
committerGergő Tisza <gtisza@wikimedia.org>
Mon, 15 Dec 2014 08:25:04 +0000 (08:25 +0000)
commitcf5f6414ce5383bb94ff3bfba6a607986242ed35
tree2deab7b1c254de962635d9c2d0097f44988da820
parente86a49424c1f7a15913b6aae2f00b5d7c0490788
Add better error message for files which exceeds $wgMaxImageArea

Added a TransformTooBigImageAreaError to allow setting an extra message.
Added also size-*pixel messages to show the value of $wgMaxImageArea
with some formatting.

This error is still throwing for all files, to fix bug T34387 this needs
a follow up with a proper check. I am not sure, if a File::isLocal() is
okay, because files from a DBForeignRepo maybe transformed on the same
server, so the check needs to be done also for this. For APIForeignRepo
the check is done on the foreign server.

Change-Id: Ieba12e424c8bddb1961a30d3f9ea5c8ff241abb5
autoload.php
includes/media/MediaTransformOutput.php
includes/media/TransformationalImageHandler.php
languages/i18n/en.json
languages/i18n/qqq.json
tests/phpunit/includes/media/BitmapScalingTest.php