Cleanup.

* Added Eclipse cleanup settings.
* Added code to quit cleanly.