A_Gallery_Storage_Frame_Event

Class A_Gallery_Storage_Frame_Event.

Defined (1)

The class is defined in the following location(s).

/products/photocrati_nextgen/modules/attach_to_post/package.module.attach_to_post.php  
  1. class A_Gallery_Storage_Frame_Event extends Mixin 
  2. function generate_thumbnail($image, $params = null, $skip_defaults = false) 
  3. $retval = $this->call_parent('generate_thumbnail', $image, $params, $skip_defaults); 
  4. if (is_admin() && ($image = C_Image_Mapper::get_instance()->find($image))) { 
  5. $controller = C_Display_Type_Controller::get_instance(); 
  6. $storage = C_Gallery_Storage::get_instance(); 
  7. $app = C_Router::get_instance()->get_routed_app(); 
  8. $image->thumb_url = $controller->set_param_for($app->get_routed_url(TRUE), 'timestamp', time(), NULL, $storage->get_thumb_url($image)); 
  9. $event = new stdClass(); 
  10. $event->pid = $image->{$image->id_field}; 
  11. $event->id_field = $image->id_field; 
  12. $event->thumb_url = $image->thumb_url; 
  13. C_Frame_Event_Publisher::get_instance('attach_to_post')->add_event(array('event' => 'thumbnail_modified', 'image' => $event)); 
  14. return $retval;