Fix broken references to window.editor.