Closed
Bug 294731
Opened 20 years ago
Closed 20 years ago
[l10n] Bookmarks Manager page/tab title not localizable
Categories
(Camino Graveyard :: Bookmarks, defect)
Tracking
(Not tracked)
RESOLVED
FIXED
Camino0.9
People
(Reporter: m.testi, Assigned: mikepinkerton)
References
()
Details
Attachments
(1 file)
2.02 KB,
patch
|
Details | Diff | Splinter Review |
User-Agent: Mozilla/5.0 (Macintosh; U; PPC Mac OS X; en-US; rv:0.9.4.1) Gecko/2002 - Netscape 6.2, Mac OS X
Build Identifier: Mozilla/5.0 (Macintosh; U; PPC Mac OS X; en-US; rv:0.9.4.1) Gecko/2002 - Netscape 6.2, Mac OS X
When you open the BM, it has a default "Bookmarks" title on both page and tab,
which seems not localizable (I can't find anything in the .nib files about this).
Reproducible: Always
Expected Results:
The "Bookmarks" page/tab title should be localizable.
Updated•20 years ago
|
Status: UNCONFIRMED → ASSIGNED
Ever confirmed: true
Comment 1•20 years ago
|
||
We need to add "Bookmarks" = "Bookmarks" in the Localized.string file.
Attachment #184524 -
Flags: review?(joshmoz)
Assignee | ||
Updated•20 years ago
|
Target Milestone: --- → Camino0.9
Updated•20 years ago
|
Attachment #184524 -
Flags: review?(joshmoz) → review?(mozilla)
Comment 2•20 years ago
|
||
It might be better to do manual string replacement in the HTML string. And put
the html in a resource.
Comment 3•20 years ago
|
||
(In reply to comment #1)
Some quick comments:
+#import "nscore.h"
What's nscore.h imported for? If it's for NSString, that's already in
<Foundation/Foundation.h>.
+ NSString *blankPage;
+ blankPage=[NSString stringWithFormat:@"<!DOCTYPE html PUBLIC \"-//W3C//DTD
HTML 4.01
Transitional//EN\">\n<html><head><title>%@</title></head><body></body></html>",NSLocalizedString(@"Bookmarks",@"Bookmarks")];
If this is initialized each time, it should be assigned and declared
simultaneously. Also, there should be spaces around the = sign and after the
comma (style, and all that):
NSString *blankPage = [NSString stringWithFormat:@"<!DOCTYPE html PUBLIC
\"-//W3C//DTD HTML 4.01
Transitional//EN\">\n<html><head><title>%@</title></head><body></body></html>",
NSLocalizedString(@"Bookmarks",@"Bookmarks")];
(Also, the second argument to NSLocalizedString() is just thrown away, but it
doesn't matter much.)
Alternatively, we could declare |blankPage| as |static NSString * const|,
similar to what the current version does. AFAIK, localized strings aren't
changed mid-application run (but I could be wrong about that). If so, the
initialization would be inside of the call, with an if:
if (!blankPage) blankPage = ...
Finally,
+ rv = NS_NewCStringInputStream(getter_AddRefs(in),
nsDependentCString([blankPage cString]));
should use |[blankPage UTF8String]| since -cString is deprecated (or soon to be).
Comment 4•20 years ago
|
||
(In reply to comment #3)
> Alternatively, we could declare |blankPage| as |static NSString * const|,
> similar to what the current version does.
Oops, no |const|, just |static NSString *|, since it's assigned at runtime and
not a constant value.
Assignee | ||
Comment 5•20 years ago
|
||
fixed.
Status: ASSIGNED → RESOLVED
Closed: 20 years ago
Resolution: --- → FIXED
Assignee | ||
Comment 6•20 years ago
|
||
Comment on attachment 184524 [details] [diff] [review]
patch correcting the problem
i made the changes wevah suggested.
Attachment #184524 -
Flags: review?(mozilla)
Comment 7•20 years ago
|
||
I'm going to be touching this code so that we show "Bookmarks" or "History" as
appropriate. Don't panic :)
You need to log in
before you can comment on or make changes to this bug.
Description
•