Closed Bug 194918 Opened 17 years ago Closed 17 years ago

implement "Tools | Delete Mail Marked as Junk in Folder"

Categories

(SeaMonkey :: MailNews: Message Display, defect)

x86
Windows 2000
defect
Not set

Tracking

(Not tracked)

VERIFIED FIXED
mozilla1.4alpha

People

(Reporter: jglick, Assigned: sspitzer)

References

()

Details

(Whiteboard: [adt3] [junk])

Attachments

(3 files, 2 obsolete files)

http://www.mozilla.org/mailnews/specs/spam/#Menu
Add menu item: "Delete Mail Marked as Junk from Selected Folder".

Enable users to quickly empty a selected folder of msgs marked as Junk.

1. If users have junk msgs set to be moved to their Junk folder, this provides a
quick way to empty the Junk folder.

2. If users want Junk msgs identified but not moved, or manually marks msgs as
Junk but don't want them moved/deleted, this is a quick way to empty their Inbox
of marked Junk msgs.
Mail triage team: nsbeta1+/adt3
Keywords: nsbeta1nsbeta1+
Whiteboard: [adt3]
Attached patch patchSplinter Review
Attachment #118170 - Attachment is obsolete: true
this patch does a bunch of things to the tools menu:

1)  disables run filters, delete junk messages, run jmc if we are in the stand
alone msg window
2)  for the 3 pane, disables run filters, delete junk messages, run jmc if we
are in the stand alone msg window if we are viewing account central, if there
are no messages in the view, or if the current folder is news (since filters
after the fact, delete, and jmc are not supported for news yet)
3) for the 3 pane, disabled delete junk messages if this is an imap folder that
can't support delete

there's a couple xxx todo items, that I'll spin off to new bugs.

they are:

1)  when deleting junk mail in folder:

+  // XXX todo
+  // should we try to set next message after delete 
+  // to the the previous selected message, if it was not junk?
+  SetNextMessageAfterDelete(); 

2) to determine if we should enable "run filters"

+    // XXX todo, check that we have filters, and at least one is enabled

3) to determine if we should enable "run jmc"

+  case nsMsgViewCommandType::runJunkControls:

+    // XXX todo, check that we have JMC enabled?
Status: NEW → RESOLVED
Closed: 17 years ago
Resolution: --- → FIXED
Summary: Junk Mail: Menu item to empty folder of msgs marked as Junk → implement "Tools | Delete Mail Marked as Junk in Folder"
Whiteboard: [adt3] → [adt3] [junk]
Target Milestone: --- → mozilla1.4alpha
Although you "fixed" Search Messages by turning it into a JS command you've
still collided with the other commands in the existing tasksCommands commandset,
e.g. Tools/Web Development/DOM Inspector. Instead you should have put those
commands that need updating into their own commandset.
Status: RESOLVED → REOPENED
Resolution: FIXED → ---
Attachment #118414 - Flags: superreview?(sspitzer)
fixed
Status: REOPENED → RESOLVED
Closed: 17 years ago17 years ago
Resolution: --- → FIXED
Attachment #118414 - Flags: superreview?(sspitzer)
my bad checkin also caused bug #199188, but neils supplimental fix has fixed it.
Blocks: 199188
No longer blocks: 199188
Comment on attachment 118456 [details] [diff] [review]
neil's patch, plus some changes

Oops, I confused cmd_SearchMsgs with MsgSearchMessages(); :-[

And I forgot messageWindow.xul, but at least I remembered that I forgot :-)
Attachment #118456 - Flags: review+
neil fixes my patch, I fix neil patch, one happy circle!
using trunk builds 20030424 on winxp, macosx and linux this is fixed. verified.
Status: RESOLVED → VERIFIED
some notes for QA / and some spin off issues

here's what deleteJunkInFolder() does:

1) expand all.  we need to expand all threads, so we find everything
2) iterate through the view, select all the junk messages.  (clear the selection
the first time we select a message) [*issue here, see bug 205529*]
3) if we didn't clear, there was no junk, so bail out.  no need to restore the
selection since we didn't modify it.  

[potential bug to log, we did perform an expand all, should we undo that?]

4) set the next message after the delete

potential bug to log:

  // XXX todo
  // should we try to set next message after delete 
  // to the message selected before we did all this, if it was not junk?

6) 

delete the selected messages (should act like you hit the delete key)

Product: Browser → Seamonkey
You need to log in before you can comment on or make changes to this bug.