summaryrefslogtreecommitdiff
path: root/modules/gallery/helpers/gallery_event.php
AgeCommit message (Collapse)Author
2013-02-17#2006 - Add system::mark_file_for_delete API to delete files at shutdown.shadlaws
- added system::mark_file_for_delete to be called to mark a file - added system::delete_marked_files to be called at shutdown to delete the list - amended system::temp_filename to, by default, add the temp name to the list - updated a few other places in code where this should be used
2013-02-15Follow-on to 7bdccade98e76df3a7830bc45bc42321a77c709a to excludeBharat Mediratta
directories for now.
2013-02-15Every 500th request prune a single old file from var/tmp and var/logs.Bharat Mediratta
Might not be aggressive enough. Fixes #2005.
2013-02-14#2003 - Add admin/movies screen.shadlaws
Added admin/movies screen analogous to the admin/graphics screen so the user can: - see how FFmpeg is configured (path and version, similar to toolkits in admin/graphics) - get some instructions on how to install FFmpeg if not found - change the movie_allow_uploads setting - ask Gallery to rebuild their movie thumbs Specifics: - admin_movies, admin_movies.html (new) - new Movies admin screen - ffmpeg.png (new) - logo for admin screen - movie::get_ffmpeg_version (new) - return version number and date of FFmpeg - form_uploadify.html - change admin message if movie uploads are disabled - gallery_event::admin_menu - added Movies link to Settings - xss_data.txt - updated golden file for unit tests
2013-01-31#1982 - Add placeholder for albums with no album cover.shadlaws
- Added missing_album_cover.jpg placeholder image. - Modified the graphics helper to use it. Calling graphics::generate will copy it. - Modified item::remove_album_cover and gallery_event::item_created to run graphics::generate. - Added unit test to Graphics_Helper_Test.
2013-01-30Actually disable the "make album cover" option when the item is already the ↵Bharat Mediratta
album cover. Fixes #1979.
2013-01-30#1968 - Improve album cover generation/removal/etc.shadlaws
- Added stanza to Item_Model::save that handles when cover id is null. - Added logic to graphics::generate to copy/convert album cover thumbs from their item thumbs to ensure they're always jpg, and eliminate the possibility that we copy/convert a dirty thumb. - Redirected other places in code where we want to do one of the above two things to use these two functions instead (gallery_event::item_updated_data_file, item::make_album_cover, item::remove_album_cover). - Improved validation in Item_Model so only albums can have covers and all covers must be non-albums. - Added unit tests to Graphics_Helper_Test.
2013-01-21Update copyright to 2013. Fixes #1953.Bharat Mediratta
2012-05-07Fix missing date.timezone which results in a crash on startup in I18nBharat Mediratta
code. Fill in missing field and log it 25% of the time. Fixes #1853.
2012-05-06Use html::anchor consistently. Fixes #1851.Bharat Mediratta
2012-02-27Update copyright to 2012. #1822Bharat Mediratta
2011-03-02Translate user Web Site label. Link web site on user profile page.Chad Kieffer
2011-01-21Update copyright to 2011.Bharat Mediratta
2011-01-08Revert "Warn admins after login if their PHP install has the"Bharat Mediratta
This reverts commit 612ddd7050889974fc1f7e449e715b4c1129c0bb.
2010-12-29Improve the solution for #1545 by sorting the settings menu properlyBharat Mediratta
to be naturally ordered and case insensitive.
2010-12-18Warn admins after login if their PHP install has theBharat Mediratta
session.use_trans_sid feature enabled, since this will cause random logouts. Partial fix for #1316.
2010-12-17Sort the Admin > Settings menu instead of relying on module activation order.Bharat Mediratta
Requires making Menu::get() return a reference. Fixes #1545.
2010-09-13When moving a single item, just copy its permissions from its parentBharat Mediratta
album. This is totally legal since an items permissions must be the same as its parent's, and it's much faster for large installs where a complete recalculation can be very costly. Should fix #1360.
2010-09-13When deleting items, choose the first *viewable* peer as the albumBharat Mediratta
cover. Normally, all items are equally viewable, but in our unit tests we occasionally have the scenario where peers have different viewability settings which is internally consistent although only possible if you set the fields manually.
2010-09-11Only call $theme->item() if we're in a non admin theme.Bharat Mediratta
2010-09-11Use $theme->item() instead of $theme->item, otherwiseBharat Mediratta
isset($theme->item) may return true even when we don't have an actual Item_Model in there.
2010-09-06Use the absolute site url when logging out of the admin site else weBharat Mediratta
wind up with weird url doubling effects. Fixes ticket #1342.
2010-09-01One more adjustment for ticket #1216. The packaging process forcesBharat Mediratta
the default email address for admin to be unknown@unknown.com and when that happens the gallery_event::user_updated() event listener fires and sets the default values. This is hard to work around, so let's just roll with it and use unknown@unknown.com as our default placeholder. So now, if an admin sets their email address and the current values are unknown@unknown.com we adopt the admin's email address for the site's mail_from/reply_to fields.
2010-09-01Explain wtf we're doing in user_updated.Bharat Mediratta
2010-09-01Hopefully the third and final patch for #1216. Set the default from and ↵Tim Almdal
reply-to addresses to an empty string. The first time the user model is saved, set the sendmail from and reply-to addresses. Requires an update to gallery version 38.
2010-09-01Refine the patch for #1216. If the admin user changes their email address ↵Tim Almdal
update the sendmail from and reply_to fields in advanced settings. Also change this if the identity provider has changed.
2010-08-22Get rid of the move dialog and move option. Instead, replace it withBharat Mediratta
a call to Organize with the appropriate album open. I have not yet figured out how to get the SWF code to highlight the active image, but that's coming. Partial fix for #1204.
2010-08-07Add the ability to replace the source data file in Item_Model::save().Bharat Mediratta
Refactor the rotate code in Quick_Controller to replace the data file, and then have gallery_event::item_updated_data_file() pick up after the change is saved, rebuild the image and handle album covers. This is much more portable than before and it will allow any mechanism (eg: REST) to replace the source image.
2010-07-20Oops! Proper fix for #1201. My last fix just redirected back to theBharat Mediratta
main site, and didn't actually log you out.
2010-07-15Redirect users away from admin to the main site if you click logout onBharat Mediratta
the admin dashboard. Fixes ticket #1201
2010-07-15Rename Flash_Uploader to just Uploader. Modules that want to replaceBharat Mediratta
this will just replace the controller. This makes overriding that much easier in the future.
2010-07-10If the target of an item move has no album cover, make the newly moved item ↵Bharat Mediratta
the album cover. Fixes ticket #1196.
2010-07-10Wrap album deletes in a batch so that we can handle lots of cascadingBharat Mediratta
deletes in bulk. This lets us avoid the problem where we continually choose and delete album covers which makes deletes really slow. It probably also avoids huge amounts of notification emails (untested). Fixes ticket #1190.
2010-07-10Pass along the from_id when editing albums in the context menu, andBharat Mediratta
also pass it along in the form creation code. This fixes ticket #1183.
2010-07-04In the site menu, say "Delete album", "Delete photo" or "Delete movie"Bharat Mediratta
as appropriate for the item type. Fixes ticket #1175.
2010-07-03When we delete an item, make sure that we scrub it from any otherBharat Mediratta
items that may have it in the album_cover_item_id column. Fixes ticket #1172.
2010-06-20Rename "simple_uploader" to "flash_uploader" to make room for an HTMLBharat Mediratta
uploader.
2010-06-12Use "continue_url" instead of "continue" for consistency with theBharat Mediratta
reauth code.
2010-06-12Stop trying to parse the continue url in the logout controller becauseBharat Mediratta
it requires us to reproduce a bunch of complex routing logic. Instead, just have the logout link generating code generate a link that's visible to guests.
2010-06-06Don't show the rotate links if the active user can't edit the photo. Fixes ↵Bharat Mediratta
ticket #1157. Thanks to psvo.
2010-05-14Fix-ups for d98b85f7d3142676e6b4f407a18ed81564823f88Bharat Mediratta
- Pass the CSS selector of the active image in as an arg to site_menu so that quick operations know what they're operating on. - Change the ids from g-{photo,movie}-id to the generic g-item-id - Initialize ajax handlers for site menu on the photo and movie page - Drop the movie context menu, it's now in the site menu
2010-05-14Merge branch 'master' of github.com:gallery/gallery3Chad Kieffer
2010-05-14Drop context_menu for wind's photo/resize view. Move photo edit options to ↵ckieffer
the site_menu.
2010-05-10Pick a new album cover when the photo that's the current cover isBharat Mediratta
deleted. Fixes ticket #1083.
2010-05-08Deleted extra CSS class assignment for context_menu delete option.ckieffer
2010-03-05Merge branch 'master' of git://github.com/fpaterno/gallery3Bharat Mediratta
2010-03-03Update the copyright to 2010. It's only 3 months into the year :-)Bharat Mediratta
2010-03-01Fix bug #1015 : repeated ids are prohibitedFlorent Paterno
2010-02-21Revert "Fix Kohana's internal cache for Gallery's usage pattern."Andy Staudacher
This reverts commit 5ddd7c9677b644396981de7df8176a3b168ffe21.
2010-02-21Fix Kohana's internal cache for Gallery's usage pattern.Andy Staudacher
Adds a core.internal_cache_read_only config variable to Kohana's internals. Kohana's internal_cache for find_file wasn't working in Gallery because the cache would be emptied on each request after reading it from disk and before most lookups would run. 1. Bootstrap sets initial core.modules (= include path): forge, kohana23_compat, gallery. 2. Kohana::setup() loads find_file cache from disk. 3. Gallery loads list of active modules and themes, and updates the core.modules value (=include path), which forces the internal find_file cache to be empties (which makes sense). 4. Request processing starts, and thus 80% of all Kohana::find_file() triggered is_file() invocations start off with an empty find_file cache. In the case of my small Gallery installation, we're talking about 3100 is_file() invocations per request with or without internal_cache enabled. With this fix, this number is down to 800 invocations. The basic idea is that we treat the cache as read only and don't write any (possibly dirty) values to it in memory until we're sure that the include path won't change later on in the request processing. Once we know the list of active modules and themes, we can update core.modules and finally flip the read-only state of the cache and start writing to it.