convert mozilla/intl/locale/src/nsLocalModule to generic module

RESOLVED FIXED in mozilla0.9.5

Status

()

Core
Internationalization
P1
normal
RESOLVED FIXED
17 years ago
17 years ago

People

(Reporter: Chris Waterson, Assigned: Chris Waterson)

Tracking

({topembed})

Trunk
mozilla0.9.5
x86
Linux
topembed
Points:
---

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: fixed-on-trunk)

Attachments

(7 attachments)

(Assignee)

Description

17 years ago
Need to convert this to a generic module to get static build to work right.
(Assignee)

Updated

17 years ago
Status: NEW → ASSIGNED
Keywords: topembed
Priority: -- → P1
Target Milestone: --- → mozilla0.9.4
(Assignee)

Updated

17 years ago
Blocks: 93100
(Assignee)

Comment 1

17 years ago
Created attachment 45489 [details] [diff] [review]
clean up locale stuff on Unix
(Assignee)

Comment 2

17 years ago
I removed nsLocaleFactoryUnix.[h|cpp], and replaced the ad hoc module
implementation in nsLocaleModule.cpp with generic module stuff.

ftang, please review, or find somebody to review -- thanks!
(Assignee)

Comment 3

17 years ago
I should note that the above patch was made against MOZILLA_0_9_2_BRANCH. I'll
attach a patch for the trunk shortly.
(Assignee)

Updated

17 years ago
Keywords: patch

Comment 4

17 years ago
See also bug 93566 for mac
(Assignee)

Comment 5

17 years ago
Created attachment 45746 [details] [diff] [review]
also need to fix Win32
(Assignee)

Comment 6

17 years ago
For this to work, we need to apply attachment 45489 [details] [diff] [review] (for Unix), attachment 
45746 [details] [diff] [review] (for Windows), and attachment 45703 [details] [diff] [review] from bug 93556 (for Mac).
(Assignee)

Comment 7

17 years ago
...sorry, bug 93566 for Mac.

Comment 8

17 years ago
I feel so embarssed that we stil have this code here. Thanks waterson, I should 
buy you a lunch for doing this for us....

r=ftang
(Assignee)

Comment 9

17 years ago
Okay, so the above patch is not sufficient. Whoever wrote the COM glue for the
locale module was very...creative. I'm going to need to rewrite most of it. *sob*
(Assignee)

Comment 10

17 years ago
*** Bug 93566 has been marked as a duplicate of this bug. ***
(Assignee)

Comment 11

17 years ago
Created attachment 46130 [details] [diff] [review]
clean up locale a bit
(Assignee)

Comment 12

17 years ago
Okay, here's what I did.

- The old locale that tague (?) wrote had hand-coded factories for
  every class. I replaced those with generic factories as best I could.

- Along those lines, got rid of ns[IWin32|Mac|OS2|Posix]LocaleFactory.[h|cpp],
  which are not needed. (Actually, still need to do OS2, ...)

- I removed the nsI[IWin32|Mac|OS2|Posix]Locale.h interfaces (which were
  all identical), and replaced them with nsIPlatformLocale.

- Got rid of ns[I]LocalFactory.[h|cpp], as it was obsolete (assertions in
  the ctor).

- Normalized nsLocale[DLL|Module|SHLIB].cpp to use generic factory stuff

- Got rid of hard-coded CIDs and IIDs where reasonable.

Still need to test on Mac and Win32. Could use some help on OS/2 also.

Comment 13

17 years ago
I'm having trouble applying the diff. I'll look at it though.
(Assignee)

Comment 14

17 years ago
Created attachment 46144 [details] [diff] [review]
first crack at OS/2, add some fixes for Mac and Win32

Comment 15

17 years ago
What user actions excercise this code?
(Assignee)

Comment 16

17 years ago
Well, I get some assertions at startup if it's wrong, but I have _no_ idea what
it does or where it is being used.
(Assignee)

Comment 17

17 years ago
Created attachment 46191 [details] [diff] [review]
another attempt
(Assignee)

Comment 18

17 years ago
Okay, so it turns out that nsI[Mac|OS2|Posix|Win32]Locale are all subtly
different in mysterious ways. So, I've put those interfaces back the way they were.

The above patch compiles and runs on Unix and Windows, makes it at least through
the intl folder on Mac, and has an honest attempt at getting this right on OS/2.
If there are any other nits that I got wrong on the Mac side, I'll attach them
anon as my build progresses.
(Assignee)

Comment 19

17 years ago
I crash-landed this onto the trunk tonight.
assignee_accessible: 1 → 0
CC list accessible: false
qacontact_accessible: 1 → 0
Not accessible to reporter
Whiteboard: fixed-on-trunk
(Assignee)

Comment 20

17 years ago
Created attachment 46198 [details] [diff] [review]
static build fixes for Win32
assignee_accessible: 0 → 1
CC list accessible: true
qacontact_accessible: 0 → 1
Accessible to reporter
Fixing database corruption caused by bug 95743.  Pay no attention to the man
behind the curtain.
(Assignee)

Updated

17 years ago
Target Milestone: mozilla0.9.4 → mozilla0.9.5
(Assignee)

Comment 22

17 years ago
Created attachment 46797 [details] [diff] [review]
up-to-date patch for MOZILLA_0_9_2_BRANCH

Comment 23

17 years ago
Chris,

Does you branch patch have the os/2 bustage fixes you did in it?

http://bonsai.mozilla.org/cvsview2.cgi?diff_mode=context&whitespace_mode=show&su
bdir=mozilla/intl/locale/src/os2&command=DIFF_FRAMESET&file=nsLocaleModule.cpp&r
ev1=1.8&rev2=1.9&root=/cvsroot
(Assignee)

Comment 24

17 years ago
mkaply: yes, it should. I hand-merged files from the trunk, and hopefully caught
everything. When (if?) I land these, would you mind if I ping'd you to do a build?

Comment 25

17 years ago
Switching qa contact to teruko for now since it is a topembed bug.  Please
re-assign further as you see is appropriate.
QA Contact: andreasb → teruko

Comment 26

17 years ago
let's get it on 0.9.2 branch. thanks

Comment 27

17 years ago
changing qa contact to yokoyama since it is a coding modification.
QA Contact: teruko → yokoyama
(Assignee)

Comment 28

17 years ago
Checked in on the branch.
Status: ASSIGNED → RESOLVED
Last Resolved: 17 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.