Fix compatibility with Sublime Text 3

This is also a request for a `sublime-3` branch or some other new branch that won't interfere with Sublime Text 2 compatibility (while ST3 is still in beta).