Summary: | style changes made through CSSMediaRule functions insertRule() and deleteRule do not show up on the screen | ||||||||
---|---|---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Sam Weinig <sam> | ||||||
Component: | New Bugs | Assignee: | Nobody <webkit-unassigned> | ||||||
Status: | RESOLVED FIXED | ||||||||
Severity: | Normal | ||||||||
Priority: | P2 | ||||||||
Version: | 420+ | ||||||||
Hardware: | Mac | ||||||||
OS: | OS X 10.4 | ||||||||
Attachments: |
|
Description
Sam Weinig
2006-12-23 15:57:23 PST
Created attachment 11991 [details]
patch
Patch with 2 test cases. The only thing that worries me is the call to stylesheet() could return null.
Comment on attachment 11991 [details]
patch
r=me
styleSheet() is a function that can return NULL, and other spots in WebCore chck for NULL, so I think you should, too. If you know that styleSheet() should never be NULL in this case (and, according to the spec, I don't think it should), then use an ASSERT instead. Eventually, it may be worth clearing up exactly when styleSheet() can return NULL. (I believe it's only in the case of a computed style declaration.)
(In reply to comment #2) > If you know that styleSheet() should > never be NULL in this case (and, according to the spec, I don't think it > should), then use an ASSERT instead. I believe stylesheet()->styleSheetChanged() would crash as reliably as an assert, so maybe a comment is enough. Created attachment 12003 [details]
updated patch
Adds comments noting that stylesheet() can only return 0 for computed style declarations.
|