From 0db141fc62c90de376a2658868a0c3f42f45395b Mon Sep 17 00:00:00 2001 From: patdenice Date: Fri, 29 Apr 2011 17:38:59 +0000 Subject: feature:2259 Create two different methods in webservice to create/regenerate thumbnail and to regenerate websize. git-svn-id: http://piwigo.org/svn/trunk@10686 68402e56-0260-453c-a942-63ccdbb3a9ee --- admin/include/image.class.php | 2 +- admin/themes/default/template/batch_manager_global.tpl | 7 +++---- admin/themes/default/template/thumbnail.tpl | 3 +-- 3 files changed, 5 insertions(+), 7 deletions(-) (limited to 'admin') diff --git a/admin/include/image.class.php b/admin/include/image.class.php index 0fa851636..64c485887 100644 --- a/admin/include/image.class.php +++ b/admin/include/image.class.php @@ -290,7 +290,7 @@ class pwg_image if (is_null($library)) { - $library = $conf['image_library']; + $library = $conf['graphics_library']; } // Choose image library diff --git a/admin/themes/default/template/batch_manager_global.tpl b/admin/themes/default/template/batch_manager_global.tpl index abf4eb97e..96f7f42a7 100644 --- a/admin/themes/default/template/batch_manager_global.tpl +++ b/admin/themes/default/template/batch_manager_global.tpl @@ -333,7 +333,7 @@ $(document).ready(function() { } else if (jQuery('[name="selectAction"]').val() == 'regenerateThumbnails') { - type = 'thumbnail'; + resizeMethod = 'pwg.images.resizeThumbnail'; maxRequests = 3; maxwidth = jQuery('input[name="thumb_maxwidth"]').val(); maxheight = jQuery('input[name="thumb_maxheight"]').val(); @@ -343,7 +343,7 @@ $(document).ready(function() { } else if(jQuery('[name="selectAction"]').val() == 'regenerateWebsize') { - type = 'websize'; + resizeMethod = 'pwg.images.resizeWebsize'; maxRequests = 1; maxwidth = jQuery('input[name="websize_maxwidth"]').val(); maxheight = jQuery('input[name="websize_maxheight"]').val(); @@ -390,8 +390,7 @@ $(document).ready(function() { type: 'GET', url: 'ws.php', data: { - method: 'pwg.images.resize', - type: type, + method: resizeMethod, maxwidth: maxwidth, maxheight: maxheight, crop: crop, diff --git a/admin/themes/default/template/thumbnail.tpl b/admin/themes/default/template/thumbnail.tpl index 5e981c3ef..8a2dec411 100644 --- a/admin/themes/default/template/thumbnail.tpl +++ b/admin/themes/default/template/thumbnail.tpl @@ -30,9 +30,8 @@ function processThumbs(width,height,crop,follow_orientation) { type: 'GET', url: 'ws.php', data: { - method: 'pwg.images.resize', + method: 'pwg.images.resizeThumbnail', image_path: image_path, - type: 'thumbnail', maxwidth: width, maxheight: height, crop: crop, -- cgit v1.2.3