title: Recalculate height after window resize
body: <p>I have a function created that displays a 'speech-bubble' when I hover over the parent object. However the bubble is set to display above the parent object, as calculated by it's height.</p>
  
  <p>I'm trying to work this into a responsive design, and as such the width and height are both dynamic. I've tried to run the function after the window resize with the following code:</p>
  
  <pre><code>$(window).resize(function() {
      $('.popup').popup();
  }).trigger('resize');
  </code></pre>
  
  <p>This almost seems to do the trick, but it's quite buggy. You can see what I mean by checking out <a href="http://jsfiddle.net/norsewulf/jMG4K/" rel="nofollow">this jsfiddle I put together</a>.</p>
  
  <p>The speech bubble works fine before the window is resized, but once it's been resized and you hover over one of the trigger objects the speech bubble animates for what looks like 5 or so repetitions.</p>
  
  <p>No doubt this wasn't originally written for a responsive design and I'm not much of a JS developer, so if anyone sees any clear improvements that could be made I'd be happy to accept them! :D</p>