title: Cocoa: How to morph a drag image while dragging
body: <p>In Interface Builder.app (and some other cocoa apps), image dragging has a very nice/sexy effect of morphing the drag image while you drag a draggable item out of its window. </p>
  
  <p>For example in Interface Buildler.app:</p>
  
  <ol>
  <li>Show the Library Palette (⇧⌘L, or Tools Menu -> Library)</li>
  <li>Drag an item out of the Library palette</li>
  </ol>
  
  <p>NOTE: as you drag the item out of the Library Palette window, it morphs from an image of the original list item to an image of the icon of the dragged item.</p>
  
  <p>I have fully implemented drag and drop in my Application using the normal Cocoa NSDragSource/NSDragDestination facilities. </p>
  
  <p>However, I can't find a hook for doing this image morph while dragging. I'm returning the initial drag image by overriding</p>
  
  <pre><code>-[NSView dragImage:at:offset:event:pasteboard:source:slideBack:]
  </code></pre>
  
  <p>But this is only called at the beginning of the drag. </p>
  
  <p>How do you signal that you would like to replace the current drag image (ideally using the sexy morph effect).</p>