From e42f791f52c502c00d095d6bf9aa3e3989423e98 Mon Sep 17 00:00:00 2001 From: rvelices Date: Tue, 27 Dec 2011 20:26:49 +0000 Subject: feature 2541 multisize - nicer presentation on picture.php - added a maintenance purge derivatives action git-svn-id: http://piwigo.org/svn/trunk@12797 68402e56-0260-453c-a942-63ccdbb3a9ee --- themes/default/template/picture_content.tpl | 26 ++++++++++++++++++++++---- 1 file changed, 22 insertions(+), 4 deletions(-) (limited to 'themes/default/template/picture_content.tpl') diff --git a/themes/default/template/picture_content.tpl b/themes/default/template/picture_content.tpl index a4a9b4760..6fc743a02 100644 --- a/themes/default/template/picture_content.tpl +++ b/themes/default/template/picture_content.tpl @@ -4,20 +4,38 @@ {/if}> {if count($current.available_derivative_types)>1} {footer_script}{literal} -function changeImgSrc(url,type) +function changeImgSrc(url,type,display) { var theImg = document.getElementById("theMainImage"); if (theImg) { theImg.removeAttribute("width");theImg.removeAttribute("height"); theImg.src = url; + var elt = document.getElementById("derivativeSwitchLink"); + if (elt) elt.innerHTML = display; } document.cookie = 'picture_deriv=' + type; } + +function toggleDerivativeSwitchBox() +{ + var elt = document.getElementById("derivativeSwitchBox"), + ePos = document.getElementById("derivativeSwitchLink"); + if (elt.style.display==="none") + { + elt.style.position = "absolute"; + elt.style.left = (ePos.offsetLeft + 10) + "px"; + elt.style.top = (ePos.offsetTop + ePos.offsetHeight) + "px"; + elt.style.display=""; + } + else + elt.style.display="none"; +} {/literal}{/footer_script} -

+{$current.selected_derivative->get_type()|@translate} +

{/if} \ No newline at end of file -- cgit v1.2.3