Closed Bug 296309 Opened 19 years ago Closed 19 years ago

[FIXr]Add an IntrinsicState() method to nsIContent

Categories

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

x86
Linux
defect

Tracking

()

RESOLVED FIXED
mozilla1.8beta3

People

(Reporter: bzbarsky, Assigned: bzbarsky)

References

Details

Attachments

(1 file, 2 obsolete files)

I was planning to do this in bug 11011, but Allan needs this for XForms now-ish,
and this part of the patch stands on its own...
Attached patch Patch (obsolete) — Splinter Review
This creates the method and implements :checked in terms of it.  I talked to
Allan, and it looks like we'd need on the order of 20-25 bits in the event
state to do all of CSS3 UI plus my borken-image/object changes (21 as things
stand, but I may want another image state or two).  So there's no need to use
anything other than a simple bitfield for state yet.
Assignee: general → bzbarsky
Status: NEW → ASSIGNED
Attachment #185101 - Flags: superreview?(dbaron)
Attachment #185101 - Flags: review?(dbaron)
Attachment #185101 - Flags: superreview?(dbaron)
Attachment #185101 - Flags: superreview-
Attachment #185101 - Flags: review?(dbaron)
Attachment #185101 - Flags: review-
Attached patch Same but with the IID fixed (obsolete) — Splinter Review
Attachment #185101 - Attachment is obsolete: true
Attachment #185103 - Flags: superreview?(dbaron)
Attachment #185103 - Flags: review?(dbaron)
Priority: -- → P1
Summary: Add an IntrinsicState() method to nsIContent → [FIX]Add an IntrinsicState() method to nsIContent
Target Milestone: --- → mozilla1.8beta3
Comment on attachment 185103 [details] [diff] [review]
Same but with the IID fixed

Not sure if you really want the mType check in the nsHTMLInputElement changes;
it wasn't there before; perhaps an assertion instead?

I'm glad to see one use of NS_EVENT_STATE_UNSPECIFIED go; named constants for
the zero bitfield are confusing; getting rid of the other two would be nice.

r+sr=dbaron
Attachment #185103 - Flags: superreview?(dbaron)
Attachment #185103 - Flags: superreview+
Attachment #185103 - Flags: review?(dbaron)
Attachment #185103 - Flags: review+
> Not sure if you really want the mType check in the nsHTMLInputElement changes;

I do.  Before, we failed the following testcase:

  data:text/html,<style>:checked { background: red }</style><input checked>

That is, we painted a red background on that textfield.  That seems wrong to me.

I can replace the other two users of NS_EVENT_STATE_UNSPECIFIED with 0 and
remove the define if you want.
Summary: [FIX]Add an IntrinsicState() method to nsIContent → [FIXr]Add an IntrinsicState() method to nsIContent
Comment on attachment 185103 [details] [diff] [review]
Same but with the IID fixed

Requesting 1.8b3 approval.  This is some very safe arch work that xforms needs
badly and that lays the groundwork for other things we want to get done.
Attachment #185103 - Flags: approval1.8b3?
Comment on attachment 185103 [details] [diff] [review]
Same but with the IID fixed

a=chofmann
Attachment #185103 - Flags: approval1.8b3? → approval1.8b3+
Attachment #185103 - Attachment is obsolete: true
Fixed for 1.8b3.  This might have even helped Tp a tad; hard to tell...
Status: ASSIGNED → RESOLVED
Closed: 19 years ago
Resolution: --- → FIXED
Blocks: 297061
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: