-More consistent toggle hidden functionality
Backport features and fixes from ST3

-Preserve selections and viewport when performing saveas function
-Ensure file is focused when file is open
Merge remote-tracking branch 'faceless/master'