Note: There are a few cases of duplicates in user autocompletion which are being worked on.

Port |Bug 193281 - Ability to import/save e-mail messages from .eml text files to folders (Message|Copy)|

RESOLVED FIXED in seamonkey2.8

Status

SeaMonkey
MailNews: Message Display
--
enhancement
RESOLVED FIXED
6 years ago
5 years ago

People

(Reporter: squib, Assigned: InvisibleSmiley)

Tracking

(Blocks: 1 bug)

Trunk
seamonkey2.8
Dependency tree / graph

Firefox Tracking Flags

(Not tracked)

Details

Attachments

(1 attachment)

(Reporter)

Description

6 years ago
+++ This bug was initially created as a clone of Bug #193281 +++

Mozilla can easily save selected messages to .eml text file. But there is no way
to perform opposite operation, i.e. import e-mail messages from .eml file. 
Such operation would be especially useful for transporting e-mail messages from
different Mozilla installations...



This bug is about porting the patch from bug 193281 to Seamonkey.

Comment 1

6 years ago
Hmm. First we need to port .isDummy. Which bug is this from?
(Reporter)

Comment 2

6 years ago
That's from bug 474701, specifically attachment 382997 [details] [diff] [review]. I doubt you'll want that exact code, but you can probably look at the places where isDummy was added and figure out a good way to detect when you have a dummy message header.
(Assignee)

Comment 3

6 years ago
I think we can add something like this to folderDisplay.js in accordance with messageWindow.js's MessageWindowController.supportsCommand:

get isDummy()
{
  return gDBView && gDBView.keyForFirstSelectedMessage == nsMsgKey_None;
}

[I just found that the above mentioned supportsCommand method is the reason why View Source is disabled for .eml messages and that TB uses gFolderDisplay.isDummy in the equivalent method, that's why.]

Philip, will you do this or shall I give it a try?

Comment 4

6 years ago
> Philip, will you do this or shall I give it a try?
By all means give it a go. I have other bugs I am currently looking into.
(Assignee)

Comment 5

6 years ago
Created attachment 573916 [details] [diff] [review]
patch [Checkin: comment 7]
Assignee: nobody → jh
Status: NEW → ASSIGNED
Attachment #573916 - Flags: review?(mnyromyr)
(Assignee)

Updated

6 years ago
Summary: Ability to import/save e-mail messages from .eml text files to folders (Message|Copy) → Port |Bug 193281 - Ability to import/save e-mail messages from .eml text files to folders (Message|Copy)|
Version: unspecified → Trunk

Comment 6

6 years ago
Comment on attachment 573916 [details] [diff] [review]
patch [Checkin: comment 7]

Cool feature work!

Just the usual nits. ;-)

>   if(copyMenu)
>-      copyMenu.setAttribute("disabled", !aMessage);
>+      copyMenu.setAttribute("disabled", !canCopy);

Good opportunity to fixup the if as well.

>+    if (gMessageDisplay.isDummy) {
>+      let file = window.arguments[0].QueryInterface(Components.interfaces
>+                                                              .nsIFileURL).file;

No need for an artifical wrap here, imo.

>+    } else {
>+      gDBView.doCommandWithFolder(nsMsgViewCommandType.copyMessages, destMsgFolder);
>+    }
>   }

Please format the new stuff as brace-on-its-own-line (despite the rest of the function still being broken).

r/moa=me with that.
Attachment #573916 - Flags: superreview+
Attachment #573916 - Flags: review?(mnyromyr)
Attachment #573916 - Flags: review+
(Assignee)

Comment 7

6 years ago
Comment on attachment 573916 [details] [diff] [review]
patch [Checkin: comment 7]

http://hg.mozilla.org/comm-central/rev/3ab8b701b57e
with nits addressed
Attachment #573916 - Attachment description: patch → patch [Checkin: comment 7]
(Assignee)

Updated

6 years ago
Status: ASSIGNED → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
Target Milestone: --- → seamonkey2.8

Updated

5 years ago
Blocks: 738163
You need to log in before you can comment on or make changes to this bug.