https://bugs.koha-community.org/bugzilla3/show_bug.cgi?id=32642 Hammat wele <hammat.wele@inlibro.com> changed: What |Removed |Added ---------------------------------------------------------------------------- Status|Failed QA |Needs Signoff --- Comment #10 from Hammat wele <hammat.wele@inlibro.com> --- (In reply to Marcel de Rooy from comment #8)
The whole code around these images indeed requires some code digging to understand whats going on ;)
I have the impression that the new lines: if( $(".cover-slider").find(".cover-image:visible").length > 0 ){ $(".cover-slider").removeClass("cover-slides"); } should be placed elsewhere. Now they are executed after the recursive calls or the callback. But this does not yet guarantee that all images are already loaded. And it also means that the new lines could be executed repeatedly which is unneeded.
In the callback verify_cover_images we activate the spinner actually: if( $(coverSlide).find(".cover-image:visible").length < 1 ){ $(coverSlide).remove(); } else { $(coverSlide).addClass("cover-slides"); }
We should only remove the spinner when the image has been loaded locally. So shouldnt we check if the local loading has been completed? So remove the spinner in image onload and check image.complete ?
I've changed the patch, now some control on the image is made before removing the spinner and it is in the verify_cover_images, it's much better this way. -- You are receiving this mail because: You are watching all bug changes.