From 2625f8dbe01b997336f14f98267731966cce1192 Mon Sep 17 00:00:00 2001 From: Christian Fowler Date: Tue, 27 Apr 2010 04:21:59 +0000 Subject: add pImmediateRender flag to generateThumbnails and rotateImage --- FisheyeImage.php | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/FisheyeImage.php b/FisheyeImage.php index 00534e6..45534c7 100644 --- a/FisheyeImage.php +++ b/FisheyeImage.php @@ -1,6 +1,6 @@ mInfo['storage_path'] ) || $this->load() ) { $fileHash['source_file'] = BIT_ROOT_PATH.$this->mInfo['storage_path']; @@ -390,7 +390,7 @@ class FisheyeImage extends FisheyeBase { if( $rotateFunc( $fileHash ) ) { liberty_clear_thumbnails( $fileHash ); $this->mDb->query( "UPDATE `".BIT_DB_PREFIX."fisheye_image` SET `width`=`height`, `height`=`width` WHERE `content_id`=?", array( $this->mContentId ) ); - $this->generateThumbnails(); + $this->generateThumbnails( FALSE, $pImmediateRender ); } else { $this->mErrors['rotate'] = $fileHash['error']; } @@ -482,11 +482,11 @@ class FisheyeImage extends FisheyeBase { } - function generateThumbnails( $pResizeOriginal=NULL ) { + function generateThumbnails( $pResizeOriginal=NULL, $pImmediateRender=FALSE ) { global $gBitSystem; $ret = FALSE; // LibertyMime will take care of thumbnail generation of the offline thumbnailer is not active - if( $gBitSystem->isFeatureActive( 'liberty_offline_thumbnailer' ) ) { + if( $gBitSystem->isFeatureActive( 'liberty_offline_thumbnailer' ) && !$pImmediateRender ) { $query = "DELETE FROM `".BIT_DB_PREFIX."liberty_process_queue` WHERE `content_id`=?"; $this->mDb->query( $query, array( $this->mContentId ) ); -- cgit v1.3