summaryrefslogtreecommitdiff
path: root/core/helpers/graphics.php
AgeCommit message (Collapse)Author
2009-01-16Move graphics::rebuild_dirty_images to core_task::rebuild_dirty_imagesBharat Mediratta
2009-01-15Changing t() placeholder syntax from {{replace_me}} to %replace_me.Andy Staudacher
2009-01-15Simplifying the way t() is called. Refactoring localization function ↵Andy Staudacher
t($message, $options=array()) into 2 separate functions: - the new t($message, $options=array()) is for simple strings, optionally with placeholder interpolation. - t2($singular, $plural, $count, $options=array()) is for plurals.
2009-01-14Make sure that helper functions are all static. Add newBharat Mediratta
File_Structure_Test to make sure we don't regress. According to the PHP docs, the "public" keyword is implied on static functions, so remove it. Also, require private static functions to start with an _. http://php.net/manual/en/language.oop5.visibility.php
2009-01-08i18n refactoring: Rename all _() (reserved by gettext) calls to t().Andy Staudacher
- And refactor printf to our string interpolation / pluralization syntax - Also, a slight change to the translations_incomings table, using binary(16) instead of char(32) as message key.
2009-01-07Rebuild 2 images at a time.Bharat Mediratta
2009-01-06Add graphics::Can() to let us determine whether the active toolkitBharat Mediratta
supports a given function. Right now it's hardcoded to support what we know about GD.
2009-01-03Add graphics::rotateBharat Mediratta
2008-12-30Add a "Graphics Settings" page that lets admins choose which graphicsBharat Mediratta
toolkit we use. We only allow users to use one toolkit. The UI needs work!
2008-12-30More phodoc cleanup.Bharat Mediratta
2008-12-30comment cleanup.Bharat Mediratta
2008-12-29Don't let the x/y coordinates in composite go negative.Bharat Mediratta
2008-12-29Properly implement graphics::composite()Bharat Mediratta
2008-12-29Make graphics rules take named parameters. This will give us someBharat Mediratta
flexibility in the future.
2008-12-29Separate permanent messages out of the message helper and put themBharat Mediratta
into site_status. Show site status in the header in the admin theme.
2008-12-28Expand on the maintenance code to make it more robust and give theBharat Mediratta
admin more control. You can now track running tasks, resume stalled tasks, cancel running tasks, and remove finished tasks. Added graphics::compose() as a placeholder for future watermark operations. Added CSRF protection to maintenance urls.
2008-12-28First round of a task framework. Tasks are job definitions stored inBharat Mediratta
the database. They're started with admin/maintenance/start/[task_name] which sends down some JS/HTML which regularly pings the task at admin/maintenance/start/[task_id] until its done. The UI is still very rough. It works, though!
2008-12-27Ignore resizes for albums when calculating the dirty countBharat Mediratta
2008-12-26Added the concept of "permanent" messages that we show to admins. UseBharat Mediratta
this to show a "your thumbs/resizes are out of date" message whenever we change the graphics rules. Tweak watermark module to add graphics rules whenever we make a change, which triggers the graphics module to add the permanent message.
2008-12-26Added graphics::mark_all_dirty(). The watermark code now marks imagesBharat Mediratta
as dirty if the admin changes the watermark at all.
2008-12-23Only clear the dirty bit if we updated the specific target.Bharat Mediratta
2008-12-23Add very simple graphics toolkits.Bharat Mediratta
Track a set of rules in Graphics_Rule_Model which specify how we turn original images into thumbnails and resizes. There's one set of rules that applies to every image in the Gallery. Track the state of thumbs and resizes with a "dirty" bit. The new graphics helper manages the rules and can rebuild the thumbs and resizes for any images that are considered "dirty". Introduce the concept of an "album cover" which is an item that an album points to. We'll use that item as the source for the album's thumbnail/resize. Conflated with this change (sorry!) I also changed the Var table to use module_name instead of module_id. This may be marginally less efficient, but it's much easier to follow in the database.