Bug 60966 - Web Inspector: model-based CSS editing does not update @import-ed stylesheet resources
Summary: Web Inspector: model-based CSS editing does not update @import-ed stylesheet ...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Web Inspector (Deprecated) (show other bugs)
Version: 528+ (Nightly build)
Hardware: All All
: P2 Normal
Assignee: Alexander Pavlov (apavlov)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-05-17 09:31 PDT by Alexander Pavlov (apavlov)
Modified: 2011-05-18 06:33 PDT (History)
10 users (show)

See Also:


Attachments
[PATCH] Suggested fix (9.33 KB, patch)
2011-05-18 02:55 PDT, Alexander Pavlov (apavlov)
no flags Details | Formatted Diff | Diff
[PATCH] Comments addressed (11.25 KB, patch)
2011-05-18 03:21 PDT, Alexander Pavlov (apavlov)
pfeldman: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Alexander Pavlov (apavlov) 2011-05-17 09:31:21 PDT
Edit any rule from any stylesheet which is imported as
@import url(...)
and examine the Resources panel. The corresponding resource is not updated and there is no new revision there.

Upstreaming http://code.google.com/p/chromium/issues/detail?id=81838
Comment 1 Alexander Pavlov (apavlov) 2011-05-18 02:55:22 PDT
Created attachment 93890 [details]
[PATCH] Suggested fix
Comment 2 Pavel Feldman 2011-05-18 03:00:03 PDT
Comment on attachment 93890 [details]
[PATCH] Suggested fix

View in context: https://bugs.webkit.org/attachment.cgi?id=93890&action=review

> Source/WebCore/inspector/InspectorCSSAgent.cpp:273
> +                collectStyleSheets(static_cast<CSSStyleSheet*>(styleSheet), styleInfos->get(), maxImportDepth);

Could you please test this scenario?

> Source/WebCore/inspector/InspectorCSSAgent.cpp:431
> +                collectStyleSheets(static_cast<CSSStyleSheet*>(importedStyleSheet), result, depth - 1);

What if A and B import C. Does C stylesheet materialize into two different CSSStyleSheet instances?
Comment 3 Alexander Pavlov (apavlov) 2011-05-18 03:07:25 PDT
(In reply to comment #2)
> (From update of attachment 93890 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=93890&action=review
> 
> > Source/WebCore/inspector/InspectorCSSAgent.cpp:273
> > +                collectStyleSheets(static_cast<CSSStyleSheet*>(styleSheet), styleInfos->get(), maxImportDepth);
> 
> Could you please test this scenario?

Done.

> > Source/WebCore/inspector/InspectorCSSAgent.cpp:431
> > +                collectStyleSheets(static_cast<CSSStyleSheet*>(importedStyleSheet), result, depth - 1);
> 
> What if A and B import C. Does C stylesheet materialize into two different CSSStyleSheet instances?

Yes, it does.
Comment 4 Alexander Pavlov (apavlov) 2011-05-18 03:21:35 PDT
Created attachment 93893 [details]
[PATCH] Comments addressed
Comment 5 Alexander Pavlov (apavlov) 2011-05-18 06:33:54 PDT
Committed r86754: <http://trac.webkit.org/changeset/86754>