Closed Bug 572454 Opened 14 years ago Closed 14 years ago

Clean up SeaMonkey versions of getFileDisplayName

Categories

(SeaMonkey :: Preferences, defect)

defect
Not set
normal

Tracking

(Not tracked)

RESOLVED FIXED
seamonkey2.1a3

People

(Reporter: kairo, Assigned: kairo)

References

Details

Attachments

(1 file)

Bug 569542 has browser/ parts that should be ported to SeaMonkey. Should be easy to do!
The only changes from that bug that applies to SeaMonkey are just cleanup - your suite/feeds/src/FeedWriter.js and suite/common/pref/pref-applications.js contain copies of those methods, so making them consistent with all the others (including the name) makes sense, but they're not buggy.

(Ideally we'd fix this by avoiding the duplication entirely, but there's no real good common place to put this small amount of code...)
Summary: Port |Bug 569542 - App picker never uses bundle display name| to SeaMonkey → Clean up SeaMonkey versions of getFileDisplayName
This patch matches the Firefox version, I guess that's all that needs to be done here.
Assignee: nobody → kairo
Status: NEW → ASSIGNED
Attachment #456694 - Flags: review?(iann_bugzilla)
OS: Linux → All
Hardware: x86 → All
Whiteboard: [good first bug]
Comment on attachment 456694 [details] [diff] [review]
match the Firefox patch

>-function getDisplayNameForFile(aFile) {
>+function getFileDisplayName(file) {
I'd prefer we kept aFile as the argument, unless there is a particular reason to make that change.
r=me with that addressed.
Attachment #456694 - Flags: review?(iann_bugzilla) → review+
Version: unspecified → Trunk
Pushed as http://hg.mozilla.org/comm-central/rev/d4d7f0a8fe16 with the param reverted to aFile.
Status: ASSIGNED → RESOLVED
Closed: 14 years ago
Resolution: --- → FIXED
Target Milestone: --- → seamonkey2.1a3
Comment on attachment 456694 [details] [diff] [review]
match the Firefox patch

>diff --git a/suite/common/pref/pref-applications.js b/suite/common/pref/pref-applications.js
>+  return file.leafName;
...
>diff --git a/suite/feeds/src/FeedWriter.js b/suite/feeds/src/FeedWriter.js
>+    return file.fileName;
Oops; This should have been leafName too.
(In reply to comment #5)
> >diff --git a/suite/feeds/src/FeedWriter.js b/suite/feeds/src/FeedWriter.js
> >+    return file.fileName;
> Oops; This should have been leafName too.

Gah, that's a mis-port, apparently, Firefox has is correct. Bad boy me for messing this one up. :(

Will land fixup shortly with rs=Neil over IRC.
Landed this followup as http://hg.mozilla.org/comm-central/rev/d817de56d8a1
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Creator:
Created:
Updated:
Size: