mirror of
https://github.com/TangentFoxy/memex.git
synced 2024-11-22 04:54:23 +00:00
BUGFIX: make masonry recalculate layout after image's loaded
This commit is contained in:
parent
4dba144a34
commit
c68ea392e8
@ -35,10 +35,10 @@ function ViewMasonry()
|
||||
var imgLoad = imagesLoaded('.grid');
|
||||
function onAlways( instance ) {
|
||||
console.log('all images are loaded');
|
||||
//this.msnry.layout();
|
||||
this.msnry.layout();
|
||||
console.log(this.msnry);
|
||||
}
|
||||
imgLoad.on( 'always', onAlways );
|
||||
imgLoad.on( 'always', onAlways.bind(this) );
|
||||
// imgLoad.off( 'always', onAlways );
|
||||
imgLoad.on( 'progress', function(instance, image)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user