Closed Bug 39756 Opened 25 years ago Closed 24 years ago

[FEATURE] folder level charset override support (back end)

Categories

(MailNews Core :: Backend, defect, P1)

defect

Tracking

(Not tracked)

VERIFIED FIXED

People

(Reporter: nhottanscp, Assigned: nhottanscp)

Details

(Whiteboard: [nsbeta2-])

Attachments

(6 files)

This is separated from 5938 (charset override) and related to 32714 (folder charset UI). We need a functionality of folder level override charset which forces all messages in a folder to use one override charset. In the back end code, need a flag in a folder attribute (same place as the charset is stored), default as false. When the flag is on, a folder charset to be always set to override charset field. Only the manual override should override that setting.
Nominating for nsbeta2.
Keywords: nsbeta2
QA Contact: lchiang → momoi
Naoki, I'm *very* confused. I just implemeted a feature for you to pass the folder charset down for messages. I don't understand how this differs from that feature I just implemented for you guys. In addition, it's a bit late to be writing new feature bugs after the beta2 feature freeze. =(
Sorry about this has not been explained clearly. The current implementation of the folder charset matches what we requested. This bug is about an option of using a folder charset as a override charset. Depends on the language, the charset label is mostly wrong. That case, the user want to override entire folder by one charset instead of manually overriding each messages. This has been proposed in UI (32714) but not been specified clearly in the back end bug.
adding feature to the summary
Summary: folder level charset override support (back end) → [FEATURE] folder level charset override support (back end)
Putting on [nsbeta2-] radar. Pulling from beta2 per PDT mtg today.
QA Contact: momoi → lchiang
Whiteboard: [nsbeta2-]
not in beta2 according to pdt...that means m18 or later...
Target Milestone: --- → M18
is the UI a beta3 approved thing or was that futured 'cause it didn't make the feature exception date? If it was futured, then I'd like to mark this bug future as well.
The folder charset UI bug 32714 is marked as future.
Target Milestone: M18 → Future
Reassign to nhotta, this is needed for bug 32714. I probably need a help of mscott to implement this.
Assignee: mscott → nhotta
QA Contact: lchiang → momoi
Status: NEW → ASSIGNED
Target Milestone: Future → ---
Keywords: nsbeta1
OS: Windows NT → All
Priority: P3 → P1
Hardware: PC → All
Attached two patches are for adding override field to db. I got a sr=bienvenu, I need one more review. I also need a separate change to add override filed to nsIMsgMessageUrl.
r=sspitzer I notice you commit the db after setting the char set. if that is ok with bienvenu, that is ok with me.
sr=bienvenu - it's ok to commit, as long as you only call SetCharsetoverride as the result of a user interaction, e.g., a menu command.
QA contact to ji.
QA Contact: momoi → ji
I added folderCharsetOverride to nsIMsgI18NUrl and used it in libmime, implemented GetFolderCharsetOverride() for imap, local and news (almost the same implementation as GetFolderCharset(). Seth, please review the patch.
no go on that patch. instead of duplicating the code to get the nsIMsgFolder from the uri, you should move that bit code out into a separate method (for all three url implementations) and have GetFolderCharsetOverride() and GetFolderCharset() both call it.
you should also check the return value of your calls to GetMsgFolder. so + GetMsgFolder(getter_AddRefs(folder)); + NS_ENSURE_TRUE(folder, NS_ERROR_FAILURE); should be + rv = GetMsgFolder(getter_AddRefs(folder)); + NS_ENSURE_SUCCESS(rv,rv); + NS_ENSURE_TRUE(folder, NS_ERROR_FAILURE); also, instead of + nsCOMPtr<nsIMsgFolder> folder = do_QueryInterface(resource, &rv); + NS_ENSURE_SUCCESS(rv,rv); + *msgFolder = folder; how about: + rv = folder->QueryInterface(NS_GET_IID(nsIMsgFolder), (void**) msgFolder); + NS_ENSURE_SUCCESS(rv,rv); the QI will do the addref, and you don't need to create and destroy the comptr. comments?
sr=bienvenu
checked in
Status: ASSIGNED → RESOLVED
Closed: 24 years ago
Resolution: --- → FIXED
Naoki, can you verify this bug? If so, please change the QA contact.
Verified. Used win32 build ID 2001012205. Used the attached data which is not readable, I set a folder charset to ISO-2022-JP and set an override flag then I was able to see the body as correct Japanese.
Status: RESOLVED → VERIFIED
Product: MailNews → Core
Product: Core → MailNews Core
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: