ビヘイビア js ファイルを次のように更新します。
$K2('.sigProGalleriaLink').click(function(event){
console.log("here");
event.preventDefault();
// Prevent clicks upon animation
if($K2(':animated').length) return false;
// Assign element
var el = $K2(this);
// Parent container
var outerContainer = el.parent().parent().parent().parent().parent();
var placeholderContainer = $K2(".sigProGalleriaPlaceholderContainer div:first");
console.log(outerContainer );
console.log(placeholderContainer);
// Placeholder elements
var targetLink = placeholderContainer.find("a:first");
console.log(targetLink );
var targetTitle = placeholderContainer.find("p:first");
console.log(targetTitle );
var targetImg = targetLink.find("img:first");
console.log(targetImg );
// Source elements
var sourceLinkHref = el.attr("href");
console.log(sourceLinkHref );
var sourceLinkTitle = el.attr("title");
console.log(sourceLinkTitle );
var sourceImage = el.find("img:first");
console.log(sourceImage );
if(targetLink.attr("href")!==sourceLinkHref){
console.log("should do the animation");
if(el.find("span:nth-child(2)")){
var sourceTitle = el.find(".sigProCaption").html();
} else {
var sourceTitle = false;
}
placeholderContainer.animate({'opacity':0},300,function(){
targetImg.attr("src",sourceLinkHref);
var counter = 0;
targetImg.load(function(){
if (counter++ == 0) {
targetImg.attr("title",sourceImage.attr("title"));
targetImg.attr("alt",sourceImage.attr("alt"));
targetLink.attr("href",sourceLinkHref);
targetLink.attr("title",sourceLinkTitle);
if(targetTitle.hasClass('sigProGalleriaTargetTitle') && sourceTitle) targetTitle.html(sourceTitle);
placeholderContainer.animate({'opacity':1},600);
}
});
}); //.delay(500).animate({'opacity':1},300);
}
// Set class for current thumb
var thumbs = outerContainer.find("ul:first").find("a");
thumbs.each(function(){
if($K2(this).hasClass('sigProLinkSelected')){
$K2(this).removeClass('sigProLinkSelected');
}
});
el.addClass('sigProLinkSelected');
});