]> git.mxchange.org Git - quix0rs-gnu-social.git/commit
Dynamically generate thumbnails (see full text)
authorMikael Nordfeldth <mmn@hethane.se>
Mon, 21 Apr 2014 18:39:28 +0000 (20:39 +0200)
committerMikael Nordfeldth <mmn@hethane.se>
Mon, 21 Apr 2014 18:46:11 +0000 (20:46 +0200)
commitd59eb5e184591953ace103522b2db4a00ecd7777
treecefe00e0c28a074bef2e49a89ffd46b2ccc683c7
parent7f3611c51c53acb46e17189194f0ed82beee7914
Dynamically generate thumbnails (see full text)

The File object now stores width and height of files that can
supply this kind of information. Formats which we can not read
natively in PHP do not currently benefit from this. However an
event hook will be introduced later.

The CreateFileImageThumbnail event is renamed to:
CreateFileImageThumbnailSource to clarify that the hooks should not
generate their own thumbnails but only the source image. Also it now
accepts File objects, not MediaFile objects.

The thumbnail generation is documented in the source code. For
developers, call 'getThumbnail' on a File object and hope for the best.

Default thumbnail sizes have increased to be more appealing.
14 files changed:
EVENTS.txt
actions/attachment_thumbnail.php
classes/File.php
classes/File_oembed.php
classes/File_thumbnail.php
lib/attachmentlist.php
lib/default.php
lib/imagefile.php
lib/inlineattachmentlist.php
lib/mediafile.php
lib/oembedhelper.php
plugins/Bookmark/forms/bookmark.php
plugins/VideoThumbnails/VideoThumbnailsPlugin.php
scripts/upgrade.php