Closed Bug 183299 Opened 22 years ago Closed 22 years ago

[FIXr]CreateSheet/LoadSheet issue with mIsSyncLoad

Categories

(Core :: CSS Parsing and Computation, defect, P1)

defect

Tracking

()

RESOLVED FIXED
mozilla1.3beta

People

(Reporter: bzbarsky, Assigned: bzbarsky)

References

Details

(Whiteboard: [whitebox])

Attachments

(1 file, 1 obsolete file)

Just thought about this some more and we have a slight problem if someone tries
to use a single loader to load the same sheet as a UA sheet synchronously and as
any sort of sheet asynchronously.  CreateSheet will find the existing load and
clone the sheet, then LoadSheet will synchronously parse into it.

The solution, methinks, is to tell CreateSheet whether the load is sync...
Depends on: 107567
Whiteboard: [whitebox]
Blocks: 183859
No longer blocks: 183859
Blocks: 183859
Attached patch This should do the job.... (obsolete) — Splinter Review
This patch has tiny bits of the bug 182124 patch in it...
Attachment #108455 - Flags: superreview?(peterv)
Attachment #108455 - Flags: review?(bugmail)
Priority: -- → P1
Summary: CreateSheet/LoadSheet issue with mIsSyncLoad → [FIX]CreateSheet/LoadSheet issue with mIsSyncLoad
Target Milestone: --- → mozilla1.3beta
Comment on attachment 108455 [details] [diff] [review]
This should do the job....

r=sicking

However i'm not compleatly happy with the way the |if(!sheet)| tests are being
nested. I dislike code that is too deeply nested since it's hard to read, but
if you think it's worth the extra saved cycles then i won't hold the review for
that.

(don't forget to take the 182124 parts out of there before landing)
Attachment #108455 - Flags: review?(bugmail) → review+
I wonder if another way to fix this would be to merge the two checks for
"existing stylesheets" that we have. I.e. that both ::CreateSheet and
::LoadSheet checks if we have an existing load?
Attachment #108455 - Flags: superreview?(peterv) → superreview+
Yeah, merging it would work too.  I still have not found a satisfactory way to
do that (the fact that inline sheets do not go through LoadSheet does not help;
but they also don't get cached so maybe I could just make a copy of the "create
a brand new sheet" code in LoadInlineSheet....).
Summary: [FIX]CreateSheet/LoadSheet issue with mIsSyncLoad → [FIXr]CreateSheet/LoadSheet issue with mIsSyncLoad
Attachment #108455 - Flags: approval1.3a?
Comment on attachment 108455 [details] [diff] [review]
This should do the job....

We're trying to wrap up 1.3a and this doesn't look like a blocker. Please hold
until we open up for beta (soon). Thanks
Attachment #108455 - Flags: approval1.3a? → approval1.3a-
Attached patch de-tangled patchSplinter Review
Attachment #108455 - Attachment is obsolete: true
fixed.
Status: NEW → RESOLVED
Closed: 22 years ago
Resolution: --- → FIXED
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: