Closed
Bug 637251
Opened 13 years ago
Closed 2 years ago
fileField can display non-ascii characters incorrectly (In Thunderbird, the file name is garbled in Photo tab of a contact)
Categories
(Toolkit :: UI Widgets, defect)
Toolkit
UI Widgets
Tracking
()
RESOLVED
INACTIVE
People
(Reporter: eagle.lu, Unassigned)
Details
(Keywords: intl)
Attachments
(1 file, 2 obsolete files)
923 bytes,
patch
|
neil
:
review+
|
Details | Diff | Splinter Review |
locale: zh-CN.UTF-8 Steps to reproduce: 1)Launch #thunderbird 2)Create a New Contact from File->New->Address Book Contact 3)Input the contact details and in Photo tab select a localized image file in "On this computer" field Result: Localized image filename is garbled in this field
Assignee: nobody → brian.lu
Attachment #515570 -
Flags: review?(bugzilla)
Comment 2•13 years ago
|
||
Comment on attachment 515570 [details] [diff] [review] set filefield label to path name explicitly Whilst this works around the issue, I'm not convinced it is the correct fix. The really issue appears to be here: http://hg.mozilla.org/mozilla-central/annotate/1240004b90e6/toolkit/content/widgets/filefield.xml#l71 nsIURL.fileName may contain escaped characters. So if we don't want to display escaped characters I think that is the place where it looks like we should fix it. Fixing the core issue would also fix the case where we're re-opening the dialog, which this patch currently misses.
Attachment #515570 -
Flags: review?(bugzilla) → review-
Comment 3•13 years ago
|
||
Looks like this is a bug in the <filefield> implementation - it gets the name by converting the file to a URL (!) which encodes non-ascii characters.
Comment 4•13 years ago
|
||
Looks like the code did this ever since Ben's first check in 6 years ago.
Attachment #515570 -
Attachment is obsolete: true
Attachment #519343 -
Flags: review?(neil)
Comment 6•13 years ago
|
||
Comment on attachment 519343 [details] [diff] [review] fix in filefield >+ let lf = aFile.QueryInterface(Components.interfaces.nsILocalFile); You don't need nsILocalFile; path is an attribute on nsIFile. Also newFileURI will already fail if aFile isn't an nsIFile, so you don't need both cases. >+ return lf.path; Did you mean the whole path? I would have thought the leafName would suffice (leafName is also an attribute on nsIFile of course).
Attachment #519343 -
Flags: review?(neil) → review-
Attachment #519343 -
Attachment is obsolete: true
Attachment #519582 -
Flags: review?(neil)
Updated•13 years ago
|
Attachment #519582 -
Flags: review?(neil) → review+
Comment 8•13 years ago
|
||
As this is really a bug in toolkit, moving to the toolkit product.
Component: Address Book → XUL Widgets
Product: Thunderbird → Toolkit
QA Contact: address-book → xul.widgets
Summary: [thunderbird]file name is garbled in Photo tab of a contact → fileField can display non-ascii characters incorrectly (In Thunderbird, the file name is garbled in Photo tab of a contact)
Updated•13 years ago
|
OS: Linux → All
Hardware: x86 → All
Comment 9•2 years ago
|
||
The bug assignee didn't login in Bugzilla in the last 7 months.
:mstriemer, could you have a look please?
For more information, please visit auto_nag documentation.
Assignee: eagle.lu → nobody
Flags: needinfo?(mstriemer)
Comment 10•2 years ago
|
||
I can't find the file that was patched here.
Status: NEW → RESOLVED
Closed: 2 years ago
Flags: needinfo?(mstriemer)
Resolution: --- → INACTIVE
You need to log in
before you can comment on or make changes to this bug.
Description
•