Closed
Bug 700899
Opened 13 years ago
Closed 13 years ago
Port |Bug 193281 - Ability to import/save e-mail messages from .eml text files to folders (Message|Copy)|
Categories
(SeaMonkey :: MailNews: Message Display, enhancement)
SeaMonkey
MailNews: Message Display
Tracking
(Not tracked)
RESOLVED
FIXED
seamonkey2.8
People
(Reporter: squib, Assigned: InvisibleSmiley)
References
(Blocks 1 open bug)
Details
Attachments
(1 file)
4.76 KB,
patch
|
mnyromyr
:
review+
mnyromyr
:
superreview+
|
Details | Diff | Splinter Review |
+++ 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•13 years ago
|
||
Hmm. First we need to port .isDummy. Which bug is this from?
Reporter | ||
Comment 2•13 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•13 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•13 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•13 years ago
|
||
Assignee | ||
Updated•13 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•13 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•13 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•13 years ago
|
Status: ASSIGNED → RESOLVED
Closed: 13 years ago
Resolution: --- → FIXED
Target Milestone: --- → seamonkey2.8
You need to log in
before you can comment on or make changes to this bug.
Description
•