From 66f3b50d23896b83c9b654b15e73367b374e5014 Mon Sep 17 00:00:00 2001 From: Dan Stillman Date: Thu, 4 Jan 2007 22:39:00 +0000 Subject: [PATCH] Restoring the previous behavior of not automatically selecting items on modify, since it meant that if you're editing an item and then purposely scrolled down to another item and then started to edit the note, the items pane will jump back to the note you're editing. I think that's probably more annoying than the alternative, which is an item potentially jumping off the screen when you edit it. We could perhaps be smarter about this and, say, jump back only if the item was visible before the modification. The best solution, probably, would be a keystroke to show the active item, like Command-L in iTunes, but I don't know what keystroke is worth stealing for that purpose... --- chrome/content/zotero/xpcom/itemTreeView.js | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/chrome/content/zotero/xpcom/itemTreeView.js b/chrome/content/zotero/xpcom/itemTreeView.js index 85846614f..10c85b7ac 100644 --- a/chrome/content/zotero/xpcom/itemTreeView.js +++ b/chrome/content/zotero/xpcom/itemTreeView.js @@ -305,9 +305,7 @@ Zotero.ItemTreeView.prototype.notify = function(action, type, ids) } } - // Reselect item (in case the sort order changed and the item - // went off-screen) - this.selectItem(ids[0]); + this.rememberSelection(savedSelection); } else { @@ -757,7 +755,6 @@ Zotero.ItemTreeView.prototype.saveSelection = function() savedSelection.push(this._getItemAtRow(j).ref.getID()); } } - return savedSelection; }