Commit graph

81 commits

Author SHA1 Message Date
Raimond Spekking
042a49ab7d * (bug 12797) Add $wgGalleryOptions for adjusting of default gallery display options
Reapply of r63197 (reverted with r63261). Per suggestion of demon now with 1 array with keys and w/o breaking parsertests
2010-03-13 11:42:04 +00:00
Chad Horohoe
b3a382a0d5 Revert r63197 '(bug 12797) Allow adjusting of default gallery display options' Breaks gallery parser test, also I don't really like introducing 5 new globals for this...maybe 1 array with keys? 2010-03-05 00:27:20 +00:00
Raimond Spekking
260cc188fa (bug 12797) Allow adjusting of default gallery display options 2010-03-03 13:07:23 +00:00
Alexandre Emsenhuber
90a4cc319f Fixed some doxygen warnings 2010-03-01 21:36:57 +00:00
Tim Starling
831b6d2bf7 * Per my CR comments on r44560: merged FileCache into RepoGroup and fixed wfFindFile() global function bloat. Did not port unused functions such as the batch loading functions.
* Fixed the formal parameter bloat in the file finding functions by making wfFindFile(), RepoGroup::findFile() and FileRepo::findFile() take an associative array of options instead of a rapidly growing collection of formal parameters. Maintained backwards compatibility for the $time parameter, which was the only one used in an extension.
* Took the advice of the todo comment on FileRepo::findFiles() and implemented a calling convention for specifying times (and other options)
* Removed the file object cache from Parser, redundant with the RepoGroup file cache
* Deleted clueless and non-functional LocalRepo::findFiles(). Does not respect redirects, deletion bitfields, or anything else nuanced about FileRepo::findFile(). Does not have the same calling convention as FileRepo::findFiles().
2009-08-15 09:59:59 +00:00
Remember the dot
700bcb30b0 Applied image attribute improvements from r52726 to galleries as well 2009-07-15 04:18:16 +00:00
Siebrand Mazeland
4698398e0f Follow-up to r51543: Fix another syntax error in ImageGallery.php. Sorry. 2009-06-06 17:07:17 +00:00
Siebrand Mazeland
ee7c479bca Follow-up to r51543: Fix syntax error in ImageGallery.php 2009-06-06 17:05:48 +00:00
Siebrand Mazeland
0d3a39aec4 * replace use of deprecated makeLink() by link() in core
* replace other deprecated Linker::*link*() methods in special pages
2009-06-06 17:00:20 +00:00
Raimond Spekking
7503af444b * Replace hardcoded '...' as indication of a truncation with the 'ellipsis' message
Per Brion's suggestion in http://lists.wikimedia.org/pipermail/wikitech-l/2008-December/040796.html
2009-02-13 19:13:48 +00:00
Ilmari Karonen
34fb6297cd Step 2 in NS_IMAGE -> NS_FILE transition (bug 44) (WARNING: huge commit).
This is a global search and replace of NS_IMAGE and NS_IMAGE_TALK with NS_FILE and NS_FILE_TALK respectively in all core files, excluding those already updated in step 1 (r44004).
2008-12-01 17:14:30 +00:00
Alexandre Emsenhuber
087a9f70c5 WARNING: HUGE COMMIT
Doxygen documentation update:
* Changed alls @addtogroup to @ingroup. @addtogroup adds the comment to the group description, but doesn't add the file, class, function, ... to the group like @ingroup does. See for example http://svn.wikimedia.org/doc/group__SpecialPage.html where it's impossible to see related files, classes, ... that should belong to that group.
* Added @file to file description, it seems that it should be explicitely decalred for file descriptions, otherwise doxygen will think that the comment document the first class, variabled, function, ... that is in that file.
* Removed some empty comments
* Removed some ?>

Added following groups:
* ExternalStorage
* JobQueue
* MaintenanceLanguage

One more thing: there are still a lot of warnings when generating the doc.
2008-05-20 17:13:28 +00:00
Aaron Schulz
c651692075 Stabilize image description links 2008-05-19 18:55:48 +00:00
Siebrand Mazeland
79d5225c0e * remove end of line whitespace
* remove empty lines at end of file
* remove "?>" where still present
2008-04-14 07:45:50 +00:00
Alexandre Emsenhuber
ffb9afb2af Some tweaks:
* Remove ending ?> tag in NamespaceCompat.php
* Fix hook name in docs/hooks.txt
2008-03-22 14:55:29 +00:00
Brion Vibber
68e2d3a7d8 Revert r31473 -- causes fatal errors. 2008-03-03 02:17:28 +00:00
Huji
0bcdeea6a5 * (bug 13214) <gallery> doesn't resize images which are smaller than 120*120 2008-03-02 22:34:51 +00:00
Raimond Spekking
5973393937 * (bug 11321) Fix width of gallerybox when option "width=xxx" is used
See the screenshots before/after attached to the bug.
2007-09-13 08:31:14 +00:00
Tim Starling
497649c904 In OggHandler:
* Changed display style: added a "more" link which expands a box for player selection. 
* Allow return to the still image only display.
* Fixed Java detection in IE (I hope)

Elsewhere:
* Changed MediaTransformOutput::toHtml() parameters, now accepts a single associative array with well-defined elements. Allows OggHandler to distinguish between file download links and image description links. 
* Made image links consistently have an anchor tag with class=image, instead of a mixture of image and internalParse.
* Made most images have a border=0 attribute, instead of just images on the image description page. Does not appear to adversely affect display at all, it was just convenient. 
* Use the image name as the title attribute for the <a> tag, when an a caption was not given by the user
* Block centering by the auto margins method in ImageGallery
* Fixed complete breakage of the thumbnail on upload conflict feature
* TODO: test DjVu
2007-08-31 02:51:23 +00:00
Brion Vibber
e065d9c62c Order of link parameters changed in r25049; putting them back so the parser test stops whining. :) 2007-08-22 20:07:00 +00:00
Tim Starling
daf77bd5f1 In ImageGallery:
* Split "is parsing" and "respect bad images" concepts. 
* Call media handler parser hook 
* Use the $linkAttribs parameter instead of putting an <a> tag around the whole media output.
2007-08-22 13:40:22 +00:00
Brion Vibber
4d3446a8e3 * (bug 10508) Allow HTML attributes on <gallery>
* (bug 1962) Allow HTML attributes on <math>
2007-07-13 17:25:06 +00:00
Aryeh Gregor
a15c419b3d Remove ?>'s from files. They're pointless, and just asking for people to mess with the files and add trailing whitespace. (Yes, I looked over every one and reverted those that were bogus. Slash-enter a million times in less worked well enough, although it was a bit mind-numbing.) 2007-06-29 01:19:14 +00:00
Brion Vibber
95c00cce55 * (bug 10265) Fix regression in category image gallery paging 2007-06-15 15:02:44 +00:00
Aaron Schulz
17551136ff *Add BeforeGalleryFindFile, TitleLinkUpdatesAfterCompletion, BeforeParserFetchTemplateAndtitle, BeforeParserMakeImageLinkObj, BeforeParserrenderImageGallery; make parser outputs and output page record images -> timestamps used and templates -> revision ids 2007-05-31 16:01:26 +00:00
Tim Starling
ed4303922f Merged filerepo-work branch:
* Added support for configuration of an arbitrary number of commons-style file repositories.
* Split Image.php into filerepo/File.php and filerepo/LocalFile.php
* Renamed Image::getImagePath() to File::getPath()
* Added initial support for timestamp-based file fetching (OldLocalFile), to be expanded upon by aaron.
* Changed the interface for Image/File object creation: use wfFindFile() or wfLocalFile() depending on semantics
* ImageGallery::add() now accepts a title object as the first parameter
* Moved file handling operations on upload from SpecialUpload to File
* Removed path-related functions from ImageFunctions.php. Removed static path accessors from File. 
* Added a Content-Disposition header to thumb.php output
* Improved thumb.php error handling
* Updated the unit test suite to kind of partially work with modern computers. RunTests.php doesn't work just yet. Fixed an actual regression that the test suite detected -- moved some defines to Defines.php where they will be loaded consistently.
2007-05-30 21:02:32 +00:00
Nick Jenkins
bd23ec29c6 Doc tweaks:
* Seems like an opportune time to introduce "@addtogroup Media" documentation tags.
* Merge "@addtogroup Metadata" (used by Exif.php) into "@addtogroup Media".
* Few more moving comment blocks to above classes.
2007-04-24 06:53:31 +00:00
Tim Starling
b15d8cffc4 * Introduced media handler modules for file-type specific operations: thumbnailing, img_metadata, capabilities, etc.
* Deprecated $wgUseImageResize, thumbnailing will be enabled unconditionally.
* Fixed interaction of page parameter to ImagePage with the HTML file cache
* Improved error reporting for image thumbnailing
* Fixed MIME type for SVG files, will be silently changed from image/svg to image/svg+xml after loading from the database.
* Workaround for djvutoxml bug #1704049 (poor performance). Use djvudump instead.
* Fixed odd behaviour in ImagePage on DjVu thumbnailing errors
* Improved error reporting for image thumbnailing
* Added sharpening option for ImageMagick thumbnailing
* Removed Image::selectPage(), added page parameters to getWidth() and getHeight(), deprecated Image::renderThumb() and Image::getThumbnail()
* Changed default contents of img_metadata to empty string instead of a:0:{}
* Moved responsibility for respecting $wgGenerateThumbnailOnParse from the UI to Image.php
2007-04-20 12:31:36 +00:00
Raimond Spekking
83a6f40953 Missing unit 'px' added. W3C CSS validator
whines about it:
"Invalid number : width only 0 can be a length. You
 must put an unit after your number : 150"
2007-02-09 15:48:40 +00:00
Aryeh Gregor
b672f737ab * (bug 6987) Allow perrow, widths, and heights attributes for <gallery> (I deliberately called them "widths"/"heights" and not "width"/"height" because the latter two would most obviously mean width and height of the gallery itself)
* Convert <gallery> caption to, well, a <caption>
2007-02-02 03:32:03 +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
Rob Church
d03c0c2c6b (bug 8403) Respect bad image list exceptions in galleries on wiki pages 2007-01-20 22:34:05 +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
9095dd44a0 Rename ImageGallery::setCaptionSafe() to ImageGallery::setCaptionHtml(), since as Simetrical points out...it's not actually safe :D 2007-01-05 01:07:04 +00:00
Rob Church
a411a4e6f5 * Move escaping of image gallery captions to ImageGallery::setCaption()
* Allow developers to set HTML gallery captions with ImageGallery::setCaptionSafe()
* (bug 8489) Support basic links in <gallery> caption attribute
2007-01-04 19:47:11 +00:00
Nick Jenkins
ae8554c45b Completing code housekeeping stuff for rest of includes/ directory: removing unused local vars, removing unused globals, replacing extract() where simple to do, declaring output arrays before calling preg_match(), and so forth. 2006-11-29 11:43:58 +00:00
Aryeh Gregor
5f1e7225ee (bug 7892) Add media count to category page, à la subcats/pages. Used a new count() method I added to ImageGallery class. 2006-11-24 06:41:02 +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
Jens Frank
7f7e79022b (bug 6420) Render thumbnails for djvu images, show multipage preview on image page 2006-08-13 17:34:48 +00:00
Antoine Musso
82d35df0b6 Strict Standards with PHP5 2006-07-12 18:38:25 +00:00
Tim Starling
d052acf220 suppressing thumbnail generation in more places 2006-07-05 06:06:58 +00:00
Brion Vibber
e690ce7de6 Gallery code cleanup patch by Ilmari Karonen
http://bugzilla.wikimedia.org/attachment.cgi?id=2028&action=view
2006-06-29 23:27:13 +00:00
Brion Vibber
5808535e16 * Fix display of file-type icons in galleries when $wgIgnoreImageErrors is off 2006-06-25 06:23:53 +00:00
Rob Church
3d291f615b Cripple the wiki text stuff for now. It doesn't SEEM dangerous but I haven't tested the lot. 2006-06-24 00:27:16 +00:00
Rob Church
73be040a7a * (bug 2316) Add "caption" attribute to <gallery> tag
* Allow setting the skin object that ImageGallery will use; needed during parse operations (the skin must come from the ParserOptions, not $wgUser)
* Prod a few skin files and increment some cache-smashers
2006-06-24 00:12:34 +00:00
Tim Starling
043c6d2c83 Fixed inconsistent error return in Image::getThumbnail() -- was returning null if height wasn't specified, an icon thumb if it was. Made it return null all the time, and fixed ImageGallery.php to understand that return value. Also made ImageGallery give informative errors if $wgIgnoreImageErrors is off. 2006-06-17 04:11:21 +00:00
Tim Starling
02547dac72 Removed most exit() calls from the MediaWiki core, by replacing them with either a throw or by classic error checking. OutputPage::fatalError() and similar functions are deprecated, use either OutputPage::showFatalError() to return control or throw new FatalError() to relinquish it. Backwards compatibility of all interfaces has been maintained, thus extensions should continue to work and can be ported at a later date. 2006-06-07 06:40:24 +00:00
Rob Church
6069ef8be0 grr 2006-05-16 22:21:14 +00:00