Skip to content

Instantly share code, notes, and snippets.

@Crystalh
Created July 1, 2010 09:09
Show Gist options
  • Save Crystalh/459754 to your computer and use it in GitHub Desktop.
Save Crystalh/459754 to your computer and use it in GitHub Desktop.
var bbcimages = this;
if(glow('img.show').length){
glow('img.show').anim(1, {
'opacity': 0
}).on('complete', function() {
glow('img.show').removeClass("show").css("display", "none");
glow('#'+bbcimages.pages[bbcimages.currentPage].assets[itemIndex%bbcimages.pageSize].id)
.fadeIn()
.data('glow_fadeIn').on('complete', function(){
alert("fadeIn completed");
});
});
}
@Crystalh
Copy link
Author

Crystalh commented Jul 1, 2010

//fully working example

var bbcimages = this;
if(glow('img.show').length){
glow('img.show').anim(1, {
'opacity': 0
}).on('complete', function() {
glow('img.show').removeClass("show").css("display", "none");
glow('#'+bbcimages.pages[bbcimages.currentPage].assets[itemIndex%bbcimages.pageSize].id)
.fadeIn()
.data('glow_fadeIn').on('complete', function(){
glow('#'+bbcimages.pages[bbcimages.currentPage].assets[itemIndex%bbcimages.pageSize].id).addClass("show");
});
});
}

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment