Changeset 18744
- Timestamp:
- Oct 25, 2012, 5:33:32 PM (12 years ago)
- Location:
- extensions/Autosize/js
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
extensions/Autosize/js/Affiche_script.js
r18737 r18744 626 626 .bind("Finish", function (e, data) { 627 627 if (typeof imageInfos_id == "undefined") return; 628 Autosize_resize(true, options);628 629 629 }) 630 630 .bind("ON", function (e, data) { … … 635 635 } 636 636 jQuery(".errors").text("Erreur : [" + data.done + "] " + data.responseText); 637 jQuery(".errors").show().delay( 20000).hide(2000);637 jQuery(".errors").show().delay(10000).hide(2000); 638 638 return; 639 639 } 640 if (data.src) { 641 theImg = document.getElementById(theMainImage_id.replace("#", "")); 642 jQuery("#theMainImage").attr("src", data.src); 643 theImg.src = data.src; 644 if (data.src.match(RegExp(options.pictureDeriv.substr(0, 2) + ".jpg", "gi"))) { 645 theImg.src = options.imgSrc; 646 640 if (data.src) { 641 if (typeof imageInfos_id == "undefined") return; 642 if (data.src.match(RegExp(options.pictureDeriv.substr(0, 2) + ".jpg", "gi"))) { 643 // Autosize_resize(true, options); 647 644 } 648 645 } -
extensions/Autosize/js/autosize_ajax.js
r18737 r18744 18 18 function progress(success,data) { 19 19 if (success) { 20 jQuery("#theMainImage").height(params.height[derivatives.done]); 21 jQuery("#theMainImage").width(params.width[derivatives.done]); 22 23 jQuery("#theMainImage").show(); 24 jQuery("#theMainImage").trigger("ON", [{ nb: derivatives.total - derivatives.done, total: derivatives.total, done: derivatives.done,status:"ok",src:data.url}]); 20 jQuery("#theMainImage").trigger("ON", [{ nb: derivatives.total - derivatives.done, total: derivatives.total, done: derivatives.done,status:"ok",src:data.url,Width:data.Width,Height:data.Height}]); 25 21 } else { 26 22 … … 44 40 function getDerivativeUrls(nofile) { 45 41 params.max_urls = nofile.length; 42 Width = jQuery("#theMainImage").width(); 43 Height = jQuery("#theMainImage").height(); 44 46 45 jQuery(nofile).each(function (i, t) { 47 46 if (typeof t.file != "undefined") { … … 52 51 params.types.push(t.type); 53 52 params.src.push(t.file); 54 params.width.push(t.width); 55 params.height.push(t.height); 53 56 54 57 55 } else if (~jQuery.inArray(t.file, params.src)) { … … 61 59 params.types.push(t.type); 62 60 params.src.push(t.file); 63 params.width.push(t.width); 64 params.height.push(t.height); 61 65 62 } 66 63 } … … 89 86 } 90 87 } 88 data.Width = Width; 89 data.Height = Height; 91 90 progress(true, data); 92 91 }),
Note: See TracChangeset
for help on using the changeset viewer.