From d9cbcfc20ded5f1cd1af4e304415b3405631f0bc Mon Sep 17 00:00:00 2001 From: Jacob Thornton Date: Sat, 10 Sep 2011 22:54:47 -0700 Subject: wait for window load event before positioning images, doi --- docs/assets/js/application.js | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) (limited to 'docs/assets/js/application.js') diff --git a/docs/assets/js/application.js b/docs/assets/js/application.js index d1c6751ea..e39a75474 100644 --- a/docs/assets/js/application.js +++ b/docs/assets/js/application.js @@ -48,15 +48,16 @@ $(document).ready(function(){ // POSITION STATIC TWIPSIES // ======================== - $(".twipsies a").each(function () { - $(this) - .twipsy({ - live: false - , placement: $(this).attr('title') - , trigger: 'manual' - , offset: 2 + $(window).load(function () { + $(".twipsies a").each(function () { + $(this) + .twipsy({ + live: false + , placement: $(this).attr('title') + , trigger: 'manual' + , offset: 2 + }) + .trigger('twipsy:show') }) - .trigger('twipsy:show') - }) - + }) }); -- cgit v1.2.3