shiffman / learningprocessing.com

New learningprocessing.com site
68 stars 21 forks source link

setTimeout for moving canvas doesn't always work #2

Closed shiffman closed 9 years ago

shiffman commented 9 years ago

maybe need to load things in order properly?

screen shot 2015-08-12 at 10 40 22 am
scottwooden commented 9 years ago

Yeah need to figure this one was a quick fix for now!

scottwooden commented 9 years ago

Still trying to figure this out. Not sure why it's getting executed before... I'll continue to investigate but if you find a solution let me know!

shiffman commented 9 years ago

I'll take a look at this too.

shiffman commented 9 years ago

Testing with this, stay tuned:

https://gist.github.com/shiffman/22bb21705ce2829207b1

shiffman commented 9 years ago

Ok, looks like solution is:

  <script language="javascript">
    window.onload = function() {
      $('#defaultCanvas').appendTo("#sketch-container");
    };
  </script>

Need to find best place to interject.

scottwooden commented 9 years ago

Cool! Did you want to implement that or shall I pop it in?

shiffman commented 9 years ago

Feel free to go ahead! Or I will later, either way ok.

Sent from mobile

On Aug 13, 2015, at 1:23 PM, Scott Wooden notifications@github.com wrote:

Cool! Did you want to implement that or shall I pop it in?

— Reply to this email directly or view it on GitHub.

shiffman commented 9 years ago

added with bb2167c36d60a01d7b94403b14237ac58fa8da6f, @scottwooden feel free to move things around as needed.