r61494 MediaWiki - Code Review archive

Repository:MediaWiki
Revision:r61493‎ | r61494 | r61495 >
Date:17:48, 25 January 2010
Author:raymond
Status:ok
Tags:
Comment:
* Fix indention for entry and i18n file. Always use tabs
* Make extension credits consistent to our other extensions
* Change extension type from 'other' to 'media' (compare to OggHandler and PdfHandler)
* Add extension to translatewiki
Modified paths:
  • /trunk/extensions/PagedTiffHandler/PagedTiffHandler.i18n.php (modified) (history)
  • /trunk/extensions/PagedTiffHandler/PagedTiffHandler.php (modified) (history)
  • /trunk/extensions/Translate/groups/mediawiki-defines.txt (modified) (history)

Diff [purge]

Index: trunk/extensions/PagedTiffHandler/PagedTiffHandler.i18n.php
@@ -11,19 +11,19 @@
1212 * @author Hallo Welt! - Medienwerkstatt GmbH
1313 */
1414 $messages['en'] = array(
15 - 'tiff-desc' => 'Handler for viewing TIFF files in image mode',
 15+ 'tiff-desc' => 'Handler for viewing TIFF files in image mode',
1616 'tiff_no_metadata' => 'Cannot get metadata from TIFF',
17 - 'tiff_page_error' => 'Page number not in range',
18 - 'tiff_too_many_embed_files' => 'The image contains too many embedded files.',
19 - 'tiff_sourcefile_too_large' => 'The resolution of the source file is too large. No thumbnail will be generated.',
20 - 'tiff_file_too_large' => 'The uploaded file is too large and was rejected.',
21 - 'tiff_out_of_service' => 'The uploaded file could not be processed. ImageMagick is not available.',
22 - 'tiff_too_much_meta' => 'Metadata uses too much space.',
23 - 'tiff_error_cached' => 'This file can only be rerendered after the the caching interval.',
24 - 'tiff_size_error' => 'The reported file size does not match the actual file size.',
25 - 'tiff_script_detected' => 'The uploaded file contains scripts.',
26 - 'tiff_bad_file' => 'The uploaded file contains errors.',
27 - 'tiff-file-info-size' => '(page $5, $1 × $2 pixel, file size: $3, MIME type: $4)',
 17+ 'tiff_page_error' => 'Page number not in range',
 18+ 'tiff_too_many_embed_files' => 'The image contains too many embedded files.',
 19+ 'tiff_sourcefile_too_large' => 'The resolution of the source file is too large. No thumbnail will be generated.',
 20+ 'tiff_file_too_large' => 'The uploaded file is too large and was rejected.',
 21+ 'tiff_out_of_service' => 'The uploaded file could not be processed. ImageMagick is not available.',
 22+ 'tiff_too_much_meta' => 'Metadata uses too much space.',
 23+ 'tiff_error_cached' => 'This file can only be rerendered after the the caching interval.',
 24+ 'tiff_size_error' => 'The reported file size does not match the actual file size.',
 25+ 'tiff_script_detected' => 'The uploaded file contains scripts.',
 26+ 'tiff_bad_file' => 'The uploaded file contains errors.',
 27+ 'tiff-file-info-size' => '(page $5, $1 × $2 pixel, file size: $3, MIME type: $4)',
2828 );
2929
3030 /** Message documentation (Message documentation)
@@ -31,18 +31,18 @@
3232 */
3333 $messages['qqq'] = array(
3434 'tiff-desc' => 'Short description of the extension, shown in [[Special:Version]]. Do not translate or change links.',
35 - 'tiff_no_metadata' => 'Error message shown when no metadata extraction is not possible',
36 - 'tiff_page_error' => 'Error message shown when page number is out of range',
37 - 'tiff_too_many_embed_files' => 'Error message shown when the uploaded image contains too many embedded files.',
38 - 'tiff_sourcefile_too_large' => 'Error message shown when the resolution of the source file is too large.',
39 - 'tiff_file_too_large' => 'Error message shown when the uploaded file is too large.',
40 - 'tiff_out_of_service' => 'Error message shown when the uploaded file could not be processed by external renderer (ImageMagick).',
41 - 'tiff_too_much_meta' => 'Error message shown when the metadata uses too much space.',
42 - 'tiff_error_cached' => 'Error message shown when a error occurres and it is cached.',
43 - 'tiff_size_error' => 'Error message shown when the reported file size does not match the actual file size.',
44 - 'tiff_script_detected' => 'Error message shown when the uploaded file contains scripts.',
45 - 'tiff_bad_file' => 'Error message shown when the uploaded file contains errors.',
46 - 'tiff-file-info-size' => 'Information about the image dimensions etc. on image page. Extended by page information',
 35+ 'tiff_no_metadata' => 'Error message shown when no metadata extraction is not possible',
 36+ 'tiff_page_error' => 'Error message shown when page number is out of range',
 37+ 'tiff_too_many_embed_files' => 'Error message shown when the uploaded image contains too many embedded files.',
 38+ 'tiff_sourcefile_too_large' => 'Error message shown when the resolution of the source file is too large.',
 39+ 'tiff_file_too_large' => 'Error message shown when the uploaded file is too large.',
 40+ 'tiff_out_of_service' => 'Error message shown when the uploaded file could not be processed by external renderer (ImageMagick).',
 41+ 'tiff_too_much_meta' => 'Error message shown when the metadata uses too much space.',
 42+ 'tiff_error_cached' => 'Error message shown when a error occurres and it is cached.',
 43+ 'tiff_size_error' => 'Error message shown when the reported file size does not match the actual file size.',
 44+ 'tiff_script_detected' => 'Error message shown when the uploaded file contains scripts.',
 45+ 'tiff_bad_file' => 'Error message shown when the uploaded file contains errors.',
 46+ 'tiff-file-info-size' => 'Information about the image dimensions etc. on image page. Extended by page information',
4747 );
4848
4949 /** German (Deutsch)
@@ -52,14 +52,14 @@
5353 'tiff-desc' => 'Schnittstelle für die Ansicht von TIFF-Dateien im Bilder-Modus',
5454 'tiff_no_metadata' => 'Keine Metadaten im TIFF vorhanden.',
5555 'tiff_page_error' => 'Seitenzahl außerhalb des Dokumentes.',
56 - 'tiff_too_much_embed_files' => 'Die Datei enthält zu viele eingebettete Dateien.',
57 - 'tiff_sourcefile_too_large' => 'Die Quelldatei hat eine zu hohe Auflösung. Es wird kein Thumbnail generiert.',
58 - 'tiff_file_too_large' => 'Die hochgeladene Datei ist zu groß und wurde abgewiesen.',
59 - 'tiff_out_of_service' => 'Die hochgeladene Datei konnte nicht verarbeitet werden. ImageMagick ist nicht verfügbar.',
60 - 'tiff_too_much_meta' => 'Die Metadaten benötigen zu viel Speicherplatz.',
61 - 'tiff_error_cached' => 'Dies Datei kann erst nach Ablauf der Caching-Periode neu gerendert werden.',
62 - 'tiff_size_error' => 'Die errechnete Größe der Datei stimmt nicht mit der tatsächlichen überein.',
63 - 'tiff_script_detected' => 'Die hochgeladene Datei enthält Skripte.',
64 - 'tiff_bad_file' => 'Die hochgeladene Datei ist fehlerhaft.',
65 - 'tiff-file-info-size' => '(Seite $5, $1 × $2 Pixel, Dateigröße: $3, MIME-Typ: $4)',
 56+ 'tiff_too_much_embed_files' => 'Die Datei enthält zu viele eingebettete Dateien.',
 57+ 'tiff_sourcefile_too_large' => 'Die Quelldatei hat eine zu hohe Auflösung. Es wird kein Thumbnail generiert.',
 58+ 'tiff_file_too_large' => 'Die hochgeladene Datei ist zu groß und wurde abgewiesen.',
 59+ 'tiff_out_of_service' => 'Die hochgeladene Datei konnte nicht verarbeitet werden. ImageMagick ist nicht verfügbar.',
 60+ 'tiff_too_much_meta' => 'Die Metadaten benötigen zu viel Speicherplatz.',
 61+ 'tiff_error_cached' => 'Dies Datei kann erst nach Ablauf der Caching-Periode neu gerendert werden.',
 62+ 'tiff_size_error' => 'Die errechnete Größe der Datei stimmt nicht mit der tatsächlichen überein.',
 63+ 'tiff_script_detected' => 'Die hochgeladene Datei enthält Skripte.',
 64+ 'tiff_bad_file' => 'Die hochgeladene Datei ist fehlerhaft.',
 65+ 'tiff-file-info-size' => '(Seite $5, $1 × $2 Pixel, Dateigröße: $3, MIME-Typ: $4)',
6666 );
\ No newline at end of file
Index: trunk/extensions/PagedTiffHandler/PagedTiffHandler.php
@@ -40,10 +40,9 @@
4141
4242 */
4343
44 -$wgExtensionCredits['other'][] = array(
45 - 'name' => 'Paged Tiff Handler',
46 - 'svn-date' => '$LastChangedDate: 2008-12-25 00:29:44 +0000 (Thu, 25 Dec 2008) $',
47 - 'svn-revision' => '$LastChangedRevision: 45011 $',
 44+$wgExtensionCredits['media'][] = array(
 45+ 'path' => __FILE__,
 46+ 'name' => 'PagedTiffHandler',
4847 'author' => '[http://www.hallowelt.biz HalloWelt! Medienwerkstatt GmbH], Sebastian Ulbricht, Daniel Lynge, Marc Reymann, Markus Glaser for Wikimedia Deutschland',
4948 'description' => 'Handler for viewing paged TIFF files in image mode',
5049 'descriptionmsg' => 'tiff-desc',
@@ -51,21 +50,21 @@
5251 );
5352
5453 $wgTiffIdentifyRejectMessages = array(
55 - '/TIFFErrors?/',
56 - '/^identify: Compression algorithm does not support random access/',
57 - '/^identify: Old-style LZW codes, convert file/',
58 - '/^identify: Sorry, requested compression method is not configured/',
59 - '/^identify: ThunderDecode: Not enough data at scanline/',
60 - '/^identify: .+?: Read error on strip/',
61 - '/^identify: .+?: Can not read TIFF directory/',
62 - '/^identify: Not a TIFF/',
 54+ '/TIFFErrors?/',
 55+ '/^identify: Compression algorithm does not support random access/',
 56+ '/^identify: Old-style LZW codes, convert file/',
 57+ '/^identify: Sorry, requested compression method is not configured/',
 58+ '/^identify: ThunderDecode: Not enough data at scanline/',
 59+ '/^identify: .+?: Read error on strip/',
 60+ '/^identify: .+?: Can not read TIFF directory/',
 61+ '/^identify: Not a TIFF/',
6362 );
6463
6564 $wgTiffIdentifyBypassMessages = array(
66 - //'/TIFFWarnings/',
67 - //'/TIFFWarning/',
68 - '/^identify: .*TIFFReadDirectory/',
69 - '/^identify: .+?: unknown field with tag .+? encountered/'
 65+ //'/TIFFWarnings/',
 66+ //'/TIFFWarning/',
 67+ '/^identify: .*TIFFReadDirectory/',
 68+ '/^identify: .+?: unknown field with tag .+? encountered/'
7069 );
7170
7271 // Use PHP-TiffReader
Index: trunk/extensions/Translate/groups/mediawiki-defines.txt
@@ -752,6 +752,9 @@
753753
754754 Page By
755755
 756+Paged Tiff Handler
 757+descmsg = tiff-desc
 758+
756759 Password Reset
757760 aliasfile = PasswordReset/PasswordReset.alias.php
758761

Status & tagging log