make sure notes get saved when switching quickly to another item (I think this is only a problem if the new item is a note)

This commit is contained in:
Simon Kornblith 2011-03-26 22:39:24 +00:00
parent f2fba1b14c
commit 8616e7e193

View file

@ -1039,6 +1039,11 @@ var ZoteroPane = new function()
var tabs = document.getElementById('zotero-view-tabbox');
// save note when switching from a note
if(document.getElementById('zotero-item-pane-content').selectedIndex == 2) {
document.getElementById('zotero-note-editor').save();
}
// Single item selected
if (this.itemsView && this.itemsView.selection.count == 1 && this.itemsView.selection.currentIndex != -1)
{