From 5d491e56cf6d4e26ef6702cf128a3e40a3c3b298 Mon Sep 17 00:00:00 2001 From: Michael M Slusarz Date: Mon, 10 May 2010 12:46:57 -0600 Subject: [PATCH] Fix selecting messages when those messages are not part of the current viewport selection --- imp/js/DimpBase.js | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/imp/js/DimpBase.js b/imp/js/DimpBase.js index 50ceeb5c5..fc6c30d00 100644 --- a/imp/js/DimpBase.js +++ b/imp/js/DimpBase.js @@ -2670,14 +2670,9 @@ var DimpBase = { if (opts.vs) { vs = opts.vs; } else if (opts.uid) { - if (opts.mailbox) { - vs = this.viewport.getSelection().search({ imapuid: { equal: [ opts.uid ] }, view: { equal: [ opts.mailbox ] } }); - if (!vs.size() && opts.mailbox != this.folder) { - vs = this.viewport.getSelection(opts.mailbox).search({ imapuid: { equal: [ opts.uid ] } }); - } - } else { - vs = this.viewport.createSelection('dataob', opts.uid); - } + vs = opts.mailbox + ? this.viewport.createSelection('rownum', this.viewport.getAllRows()).search({ imapuid: { equal: [ opts.uid ] }, view: { equal: [ opts.mailbox ] } }) + : this.viewport.createSelection('dataob', opts.uid); } else { vs = this.viewport.getSelected(); } -- 2.11.0