Reorganize init/removal of DOM component

DOM wasn't really cleaning up after itself.  This moves all the logic to the special `remove` function, and unbinds all the events properly.  To unbind them, the event handlers are now _methods of the DOM component.

There was an also an issue where undraw would throw when the entity's element wasn't actually attached directly to the stage.  It's now just removed from its parentNode.

Adds tests to cover invalidation and cleanup.
Merge pull request #727 from starwed/dom-removal

Reorganize init/removal of DOM component