Warn user when file is already open in another view

This is for #9031 

Need to squash commits before merging

cc @JeffryBooher