Switched the subtitle editor to a class-based view

This makes it easier to re-use the view and override certain behavior.
Refactored subtitle editor view some more

Split it up a bit and moved some of its code from module-level
functions to methods.  I think this new way is cleaner and also allows
us to subclass the view and override certain things.
Allow the editor view to set the redirect URL
Merge pull request #1754 from pculture/editor-view-refactor

Editor view refactor