Closed Bug 323910 Opened 19 years ago Closed 19 years ago

Merge gklayout atom lists

Categories

(Core :: DOM: Core & HTML, defect)

defect
Not set
normal

Tracking

()

RESOLVED FIXED

People

(Reporter: sicking, Assigned: sicking)

References

Details

Attachments

(1 file, 2 obsolete files)

We currently have quite a few atom lists in gklayout, nsHTMLAtoms, nsXULAtoms, nsXBLAtoms, nsLayoutAtoms, etc. This leads to a fair amout of duplication of string data as well as differences in naming of the same value ("*" and "class" both have three different names in different classes).

The various lists also leaves some usecases without an obvious list to use. For example XMLEvents uses nsHTMLAtoms although it's not HTML specific in any way.

Patch comming up to merge all these lists into a single list, nsGkAtoms.
Attached patch Patch to fix (obsolete) — Splinter Review
This patch creates a single list, but makes the old code work by typedefing nsLayoutAtoms etc to nsGkAtoms. At a later point we should create a separate search-n-replace patch that changes all users to use nsGkAtoms directly.

I removed all duplicate atoms which meant that I had to rename a few atoms, like ::templateAtom into ::_template. However in most cases the duplicates had the same name across the different atom lists.

The content/xslt changes are slightly different then the changes to the other atom lists since transformiix standalone still needs its own atom lists. That's all #ifdef'ed though.
Attachment #208879 - Flags: superreview?(jst)
Attachment #208879 - Flags: review?(jst)
Attached patch With whitespace fixes (obsolete) — Splinter Review
Forgot to run a last diff after I had done some whitespace fixes.
Attachment #208879 - Attachment is obsolete: true
Attachment #208881 - Flags: superreview?(jst)
Attachment #208881 - Flags: review?(jst)
Attachment #208879 - Flags: superreview?(jst)
Attachment #208879 - Flags: review?(jst)
Comment on attachment 208881 [details] [diff] [review]
With whitespace fixes

+		nsGkAtomList.h \
+		nsGkAtoms.h \

maybe nsGeckoAtoms would be more readable?
I went for something short, but I can't say I feel super strongly about it.
I realized that the previous patch doesn't build when MOZ_XUL is undefined. The only difference is that this one won't create a library for content/xul/content/src when MOZ_XUL isn't defined
Attachment #208881 - Attachment is obsolete: true
Attachment #208898 - Flags: superreview?(jst)
Attachment #208898 - Flags: review?(jst)
Attachment #208881 - Flags: superreview?(jst)
Attachment #208881 - Flags: review?(jst)
Comment on attachment 208898 [details] [diff] [review]
This one's golden

Yeah, golden :) r+sr=jst
Attachment #208898 - Flags: superreview?(jst)
Attachment #208898 - Flags: superreview+
Attachment #208898 - Flags: review?(jst)
Attachment #208898 - Flags: review+
Checked in, saved just under 3k
Status: NEW → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Blocks: 355300
Component: DOM → DOM: Core & HTML
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: