すべての画像のダウンロードが完了したときにユーザーに通知するためのコードがありますが、コードの流れはあまり明確ではありません。誰でも詳細に説明できますか?jqueryコードの説明が必要
何1()関数と、それが何をするのか...負荷()関数は
$("#loadingDiv").show();
var nImages = $("#all-images").length;
var loadCounter = 0;
$("#all-images img").one("load", function() {
loadCounter++;
if(nImages == loadCounter) {
$(this).parent().show();
$("#loadingDiv").hide();
}
}).each(function() {
// attempt to defeat cases where load event does not fire
// on cached images
if(this.complete) $(this).trigger("load");
});
おかげ
[jQueryドキュメント](http://api.jquery.com/one/)でそれを見てみませんか? –