title: jquery rotate, drag and resize
body: <p>I am working on a project in which i want to drag, rotate and resize images.
  This is my first jquery project and so far things are working ok.
  Trough stackoverflow i found the plugin <a href="http://code.google.com/p/jqueryrotate/" rel="nofollow">jqueryrotate</a> which handles the rotation.</p>
  
  <p>The problem is that i now have an image which i can drag around and rotate but when i try to resize a rotated image, i get some funny results. The resizing after the rotation seems off.</p>
  
  <p>HTML</p>
  
  <pre><code>&lt;script type="text/javascript" src="http://jqueryrotate.googlecode.com/files/jQueryRotate.2.1.js"&gt;&lt;/script&gt;
      &lt;link href="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/themes/base/jquery-ui.css" rel="stylesheet" type="text/css"/&gt;
      &lt;script src="http://ajax.googleapis.com/ajax/libs/jqueryui/1.8/jquery-ui.min.js"&gt;&lt;/script&gt;    
  
  &lt;img id="resizableImage0" class="resize" width="100px" height="100px" alt="tile0" src="http://www.elaxtro.com/images/demo.png"&gt;
  &lt;img id="resizableImage1" class="resize" width="100px" height="100px" alt="tile1" src="http://www.specialized.com/OA_MEDIA/2009/bikes/9397-20_demo8_2_ano_blue_d.jpg"&gt;
  </code></pre>
  
  <p>jQuery</p>
  
  <pre><code>window.zindex = 30;
  
  $(document).ready(function() {
      $(".resize").resizable();
  
      $(".resize").parent().draggable({
          stack: "div"
      });
  
      $(".resize").rotate({
          bind: {
              dblclick: function() {
                  // get current
                  var currentAngle = $(this).get(0).Wilq32.PhotoEffect._angle;
                  var newAngle = currentAngle + 90;
                  $(this).rotate(newAngle);
              }
          }
      });
  });
  </code></pre>
  
  <p>The fiddle should make things clear.
  <a href="http://jsfiddle.net/U64se/20/" rel="nofollow">Fiddle</a></p>
  
  <p>Doubleclicking rotates an image 90 degrees :)</p>
  
  <p>Is there anyone who can help me with this.</p>
  
  <p>Thank you in advance.</p>
  
  <p>Edit: fixed the resizer in the fiddle example
  Please note that the problem is best visible if you rotate once so that the image is 90 degrees rotated. After this try to resize.</p>
  
  <p>The problem does not occur when an image is 0 degrees or 180 degrees rotated</p>