RESOLVED INVALID 81319
Web Inspector: Implement the removal of CSS rules
https://bugs.webkit.org/show_bug.cgi?id=81319
Summary Web Inspector: Implement the removal of CSS rules
Nikita Vasilyev
Reported 2012-03-16 01:42:29 PDT
Screencast: http://www.screenr.com/NkN8 Removing a rule added in Styles pane causes an error: "Error during DOMAgent operation: Server error(-32000): DOM Error while querying.". I can reproduce it on every page in WebKit Nightly and Chrome (stable, dev, and canary).
Attachments
Patch (51.19 KB, patch)
2012-04-16 07:59 PDT, Alexander Pavlov (apavlov)
no flags
Patch (51.25 KB, patch)
2012-04-16 08:46 PDT, Alexander Pavlov (apavlov)
no flags
Patch (51.33 KB, patch)
2012-04-16 09:19 PDT, Alexander Pavlov (apavlov)
pfeldman: review-
Pavel Feldman
Comment 1 2012-03-16 04:19:24 PDT
Could you please provide step-by-step repro?
Pavel Feldman
Comment 2 2012-03-16 04:22:49 PDT
(In reply to comment #1) > Could you please provide step-by-step repro? Oh, missed the attachment, never mind.
Alexander Pavlov (apavlov)
Comment 3 2012-04-16 07:59:08 PDT
Early Warning System Bot
Comment 4 2012-04-16 08:15:18 PDT
Early Warning System Bot
Comment 5 2012-04-16 08:18:07 PDT
Build Bot
Comment 6 2012-04-16 08:20:28 PDT
Alexander Pavlov (apavlov)
Comment 7 2012-04-16 08:46:49 PDT
Build Bot
Comment 8 2012-04-16 09:05:58 PDT
Alexander Pavlov (apavlov)
Comment 9 2012-04-16 09:19:54 PDT
Pavel Feldman
Comment 10 2012-04-18 05:19:37 PDT
Comment on attachment 137352 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=137352&action=review > Source/WebCore/css/CSSGrammar.y:447 > + before_ruleset ruleset { This could be a separate patch with a test. > Source/WebCore/inspector/InspectorCSSAgent.cpp:471 > + return m_styleSheet->insertRuleBefore(m_originalRuleString, m_anchorId, m_originalRuleTextRange.start, ec); This implies that you drop the information about the enabled state. > Source/WebCore/inspector/InspectorStyleSheet.cpp:63 > +struct RuleNode : public RefCounted<RuleNode> { As we agreed offline, I'd suggest that you expose the stylesheet structure via the protocol. Otherwise, you logic for insertion of a rule into a given place of the stylesheet is only accessible as an undo operation for the delete rule.
Note You need to log in before you can comment on or make changes to this bug.