processing/processing — pull request #2441 by jdf (2014-04-10 18:28:21+00:00)
Title: Allow modes to have default extensions other than "pde".

Aside from not crashing anymore, this patch changes mode-switch behavior as follows:
If you're in FooMode, and you're in an unmodified, empty sketch, the FooMode editor
is closed, and a BarMode editor is created. If you're in an unmodified, non-empty
sketch, it remains on-screen, and a new BarMode editor is created.

Fixes #2419 and #2420.