Skip to content

Commit

Permalink
Fix DOM example after breaking change to Shatter images array
Browse files Browse the repository at this point in the history
  • Loading branch information
cdgugler committed May 4, 2014
1 parent 0e7cb65 commit 2c513c5
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions examples/js/dom.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,10 @@ image.addEventListener("load", function() {
// loop through images in shatter object and insert into
// dom at correct position
for (var i = 0; i < shatter.images.length; i++) {
shatter.images[i][0].style.position = 'absolute';
shatter.images[i][0].style.left = shatter.images[i][1][0] + adjustment + 'px';
shatter.images[i][0].style.top = shatter.images[i][1][1] + 75 + 'px';
div[0].appendChild(shatter.images[i][0]);
shatter.images[i].image.style.position = 'absolute';
shatter.images[i].image.style.left = shatter.images[i].x + adjustment + 'px';
shatter.images[i].image.style.top = shatter.images[i].y + 75 + 'px';
div[0].appendChild(shatter.images[i].image);
}

// wait a bit to add dom gravity
Expand Down

0 comments on commit 2c513c5

Please sign in to comment.