Singletab

stay in the same browser tab when switching html docs in editor.
Why the timeout? Why half a second? Also, this probably should not be executed at all if the connection is in the process of establishing.