Disable auto_focus for TinyMCE
TinyMCE triggers a focus on the window itself, which means that the window steals focus when an attachment is created even if another Zotero window is in front. Instead, do a manual focus in the external note window, which is the one place I could find where we rely on it (though there might be others).
This commit is contained in:
parent
3cc92fe1e9
commit
081793f72f
3 changed files with 5 additions and 3 deletions
|
@ -709,8 +709,10 @@
|
|||
self.value = self._value;
|
||||
}
|
||||
if (self._focus) {
|
||||
self._iframe.focus();
|
||||
self._editor.focus();
|
||||
setTimeout(function () {
|
||||
self._iframe.focus();
|
||||
self._editor.focus();
|
||||
});
|
||||
self._focus = false;
|
||||
}
|
||||
|
||||
|
|
|
@ -70,6 +70,7 @@ async function onLoad() {
|
|||
noteEditor.refresh();
|
||||
}
|
||||
|
||||
noteEditor.focus();
|
||||
notifierUnregisterID = Zotero.Notifier.registerObserver(NotifyCallback, 'item', 'noteWindow');
|
||||
}
|
||||
|
||||
|
|
|
@ -10,7 +10,6 @@
|
|||
body_id: "zotero-tinymce-note",
|
||||
content_css: "css/note-content.css",
|
||||
|
||||
auto_focus: "tinymce",
|
||||
browser_spellcheck: true,
|
||||
convert_urls: false,
|
||||
entity_encoding: 'raw',
|
||||
|
|
Loading…
Reference in a new issue