[SCM] WebKit Debian packaging branch, debian/experimental, updated. upstream/1.3.3-10851-g50815da

apavlov at chromium.org apavlov at chromium.org
Wed Dec 22 17:54:10 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit 0c63b63daddc05b89c3bf50411b2ca172da001f3
Author: apavlov at chromium.org <apavlov at chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Dec 2 11:25:26 2010 +0000

    2010-12-01  Alexander Pavlov  <apavlov at chromium.org>
    
            Reviewed by Yury Semikhatsky.
    
            Web Inspector: Remove obsolete CSS backend API from InspectorDOMAgent
            https://bugs.webkit.org/show_bug.cgi?id=50318
    
            WebCore:
            * CMakeLists.txt:
            * GNUmakefile.am:
            * WebCore.gypi:
            * WebCore.order:
            * WebCore.pro:
            * WebCore.vcproj/WebCore.vcproj:
            * WebCore.xcodeproj/project.pbxproj:
            * inspector/Inspector.idl:
            * inspector/InspectorCSSAgent.h:
            * inspector/InspectorCSSStore.cpp: Removed.
            * inspector/InspectorCSSStore.h: Removed.
            * inspector/InspectorController.cpp:
            (WebCore::InspectorController::InspectorController):
            (WebCore::InspectorController::connectFrontend):
            (WebCore::InspectorController::didCommitLoad):
            * inspector/InspectorController.h:
            * inspector/InspectorDOMAgent.cpp:
            (WebCore::InspectorDOMAgent::InspectorDOMAgent):
            (WebCore::InspectorDOMAgent::unbind):
            * inspector/InspectorDOMAgent.h:
            (WebCore::InspectorDOMAgent::create):
    
            LayoutTests:
            * inspector/styles-iframe.html:
            * inspector/styles-source-lines.html:
            * inspector/styles-source-offsets-expected.txt:
            * inspector/styles-source-offsets.html:
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@73121 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 73afc37..d7f942b 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,15 @@
+2010-12-01  Alexander Pavlov  <apavlov at chromium.org>
+
+        Reviewed by Yury Semikhatsky.
+
+        Web Inspector: Remove obsolete CSS backend API from InspectorDOMAgent
+        https://bugs.webkit.org/show_bug.cgi?id=50318
+
+        * inspector/styles-iframe.html:
+        * inspector/styles-source-lines.html:
+        * inspector/styles-source-offsets-expected.txt:
+        * inspector/styles-source-offsets.html:
+
 2010-12-02  Adam Barth  <abarth at webkit.org>
 
         Reviewed by Eric Seidel.
diff --git a/LayoutTests/inspector/styles-iframe.html b/LayoutTests/inspector/styles-iframe.html
index fbacf39..2d7624a 100755
--- a/LayoutTests/inspector/styles-iframe.html
+++ b/LayoutTests/inspector/styles-iframe.html
@@ -46,7 +46,7 @@ function frontend_dumpStylesContinuation(testController)
         mainStyles = styles;
     }
 
-    InspectorBackend.getStyles(body.id, false, mainFrameCallback);
+    InspectorBackend.getStylesForNode2(body.id, mainFrameCallback);
 
     // 2. Find iframe node
     var innerMapping = WebInspector.domAgent._idToDOMNode;
@@ -67,7 +67,7 @@ function frontend_dumpStylesContinuation(testController)
         testController.notifyDone([mainStyles, styles]);
     }
 
-    InspectorBackend.getStyles(iframeBody.id, false, iframeCallback);
+    InspectorBackend.getStylesForNode2(iframeBody.id, iframeCallback);
 }
 
 </script>
diff --git a/LayoutTests/inspector/styles-source-lines.html b/LayoutTests/inspector/styles-source-lines.html
index ee01f2c..eb5aef3 100755
--- a/LayoutTests/inspector/styles-source-lines.html
+++ b/LayoutTests/inspector/styles-source-lines.html
@@ -63,6 +63,8 @@ function doit()
     {
         var matchedCSSRules = styles.matchedCSSRules;
         for (var i = 0; i < matchedCSSRules.length; ++i) {
+            if (matchedCSSRules[i].origin !== "")
+                continue;
             output("Line:" + (matchedCSSRules[i].sourceLine + 1) + "\t" + matchedCSSRules[i].selectorText);
         }
         notifyDone();
@@ -85,7 +87,7 @@ function frontend_getRawStyles(testController)
     {
         testController.notifyDone(styles);
     }
-    InspectorBackend.getStyles(WebInspector.domAgent.document.body.id, true, callback);
+    InspectorBackend.getStylesForNode2(WebInspector.domAgent.document.body.id, callback);
 }
 
 </script>
diff --git a/LayoutTests/inspector/styles-source-offsets-expected.txt b/LayoutTests/inspector/styles-source-offsets-expected.txt
index 3edd2ce..1e57997 100644
--- a/LayoutTests/inspector/styles-source-offsets-expected.txt
+++ b/LayoutTests/inspector/styles-source-offsets-expected.txt
@@ -7,7 +7,7 @@ body: [0-4] [6-266]
     important /* !important property not recognized by WebCore */' !important non-parsed] @[26-104]
 ['height':'100% !important' !important] @[109-133]
 ['colorz':'"!important"' non-parsed] @[138-159]
-['important':'' non-parsed] @[164-174]
+['important':'!important' non-parsed] @[164-185]
 ['color':'"badcolor" ! important /* good property with strange value */' !important non-parsed] @[190-259]
 body.main1: [298-336] [337-418]
 ['color':'#F00BAA'] @[13-28]
@@ -17,7 +17,7 @@ body.main2: [434-444] [445-540]
 body.mainpage: [2-15] [17-149]
 ['text-decoration':'none'] @[5-27]
 ['badproperty':'1badvalue1' non-parsed] @[107-131]
-element.style: [0-0] [0-31]
+element.style: [0-31]
 ['font-weight':'normal'] @[0-20]
 ['width':'80%'] @[21-31]
 
diff --git a/LayoutTests/inspector/styles-source-offsets.html b/LayoutTests/inspector/styles-source-offsets.html
index 979d02b..195ca55 100644
--- a/LayoutTests/inspector/styles-source-offsets.html
+++ b/LayoutTests/inspector/styles-source-offsets.html
@@ -26,27 +26,45 @@ function frontend_runTest(testController)
 {
     testController.waitUntilDone();
     frontend_expandDOMSubtree(WebInspector.domAgent.document);
+
     testController.runAfterPendingDispatches(function() {
         function stylesCallback(testController, styles)
         {
             var matchedCSSRules = styles.matchedCSSRules;
             for (var i = 0; i < matchedCSSRules.length; ++i) {
                 var rule = matchedCSSRules[i];
-                InspectorBackend.getStyleSourceData(rule.style.styleId, frontend_styleDataReceived.bind(null, testController, rule, false));
+                frontend_dumpStyleData(testController, rule, false);
             }
-            InspectorBackend.getStyleSourceData(styles.inlineStyle.styleId, frontend_styleDataReceived.bind(null, testController, styles.inlineStyle, true));
+            frontend_dumpStyleData(testController, styles.inlineStyle, true);
         }
-        InspectorBackend.getStyles(WebInspector.domAgent.document.body.id, true, stylesCallback.bind(null, testController));
+        InspectorBackend.getStylesForNode2(WebInspector.domAgent.document.body.id, stylesCallback.bind(null, testController));
     });
 }
 
-function frontend_styleDataReceived(testController, ruleOrStyle, shouldBail, data)
+function frontend_dumpStyleData(testController, ruleOrStyle, shouldBail)
 {
     var isRule = !!(ruleOrStyle.style);
-    testController.results.push((isRule ? ruleOrStyle.selectorText : "element.style") + ": [" + data.selectorRange.start + "-" + data.selectorRange.end + "] [" + data.bodyRange.start + "-" + data.bodyRange.end + "]");
-    for (var i = 0; i < data.propertyData.length; ++i) {
-        var propertyDatum = data.propertyData[i];
-        testController.results.push("['" + propertyDatum.name + "':'" + propertyDatum.value + "'" + (propertyDatum.important ? " !important" : "") + (propertyDatum.parsed ? "" : " non-parsed") +"] @[" + propertyDatum.start + "-" + propertyDatum.end + "]");
+    var style;
+    var header = "";
+    if (isRule) {
+        if (ruleOrStyle.origin !== "") {
+            if (shouldBail)
+                testController.notifyDone(testController.results);
+            return;
+        }
+        style = ruleOrStyle.style;
+        header = ruleOrStyle.selectorText + ": [" + (ruleOrStyle.selectorRange ? ruleOrStyle.selectorRange.start + "-" + ruleOrStyle.selectorRange.end : "")  + "]";
+    } else {
+        style = ruleOrStyle;
+        header = "element.style:";
+    }
+    testController.results.push(header + " [" + style.properties.startOffset  + "-" + style.properties.endOffset + "]");
+    var allProperties = style.cssProperties;
+    for (var i = 0; i < allProperties.length; ++i) {
+        var property = allProperties[i];
+        if (property.status === "style")
+            continue;
+        testController.results.push("['" + property.name + "':'" + property.value + "'" + (property.priority ? " !important" : "") + (property.parsedOk ? "" : " non-parsed") +"] @[" + property.startOffset + "-" + property.endOffset + "]");
     }
     if (shouldBail)
         testController.notifyDone(testController.results);
diff --git a/WebCore/CMakeLists.txt b/WebCore/CMakeLists.txt
index f35da2f..3bad80f 100644
--- a/WebCore/CMakeLists.txt
+++ b/WebCore/CMakeLists.txt
@@ -1124,7 +1124,6 @@ SET(WebCore_SOURCES
     inspector/InspectorApplicationCacheAgent.cpp
     inspector/InspectorBackend.cpp
     inspector/InspectorCSSAgent.cpp
-    inspector/InspectorCSSStore.cpp
     inspector/InspectorClient.cpp
     inspector/InspectorController.cpp
     inspector/InspectorDOMAgent.cpp
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index 64f203f..eee4304 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,32 @@
+2010-12-01  Alexander Pavlov  <apavlov at chromium.org>
+
+        Reviewed by Yury Semikhatsky.
+
+        Web Inspector: Remove obsolete CSS backend API from InspectorDOMAgent
+        https://bugs.webkit.org/show_bug.cgi?id=50318
+
+        * CMakeLists.txt:
+        * GNUmakefile.am:
+        * WebCore.gypi:
+        * WebCore.order:
+        * WebCore.pro:
+        * WebCore.vcproj/WebCore.vcproj:
+        * WebCore.xcodeproj/project.pbxproj:
+        * inspector/Inspector.idl:
+        * inspector/InspectorCSSAgent.h:
+        * inspector/InspectorCSSStore.cpp: Removed.
+        * inspector/InspectorCSSStore.h: Removed.
+        * inspector/InspectorController.cpp:
+        (WebCore::InspectorController::InspectorController):
+        (WebCore::InspectorController::connectFrontend):
+        (WebCore::InspectorController::didCommitLoad):
+        * inspector/InspectorController.h:
+        * inspector/InspectorDOMAgent.cpp:
+        (WebCore::InspectorDOMAgent::InspectorDOMAgent):
+        (WebCore::InspectorDOMAgent::unbind):
+        * inspector/InspectorDOMAgent.h:
+        (WebCore::InspectorDOMAgent::create):
+
 2010-12-02  Csaba Osztrogonác  <ossy at webkit.org>
 
         Unreviewed trivial buildfix after r73117.
diff --git a/WebCore/GNUmakefile.am b/WebCore/GNUmakefile.am
index 68a2394..9ec24cb 100644
--- a/WebCore/GNUmakefile.am
+++ b/WebCore/GNUmakefile.am
@@ -1897,8 +1897,6 @@ webcore_sources += \
 	WebCore/inspector/InspectorController.h \
 	WebCore/inspector/InspectorCSSAgent.cpp \
 	WebCore/inspector/InspectorCSSAgent.h \
-	WebCore/inspector/InspectorCSSStore.cpp \
-	WebCore/inspector/InspectorCSSStore.h \
 	WebCore/inspector/InspectorDatabaseResource.cpp \
 	WebCore/inspector/InspectorDatabaseResource.h \
 	WebCore/inspector/InspectorDebuggerAgent.cpp \
diff --git a/WebCore/WebCore.gypi b/WebCore/WebCore.gypi
index 2b5a0f6..e48c56a 100644
--- a/WebCore/WebCore.gypi
+++ b/WebCore/WebCore.gypi
@@ -1967,8 +1967,6 @@
             'inspector/InspectorController.h',
             'inspector/InspectorCSSAgent.cpp',
             'inspector/InspectorCSSAgent.h',
-            'inspector/InspectorCSSStore.cpp',
-            'inspector/InspectorCSSStore.h',
             'inspector/InspectorDatabaseResource.cpp',
             'inspector/InspectorDatabaseResource.h',
             'inspector/InspectorDebuggerAgent.cpp',
diff --git a/WebCore/WebCore.order b/WebCore/WebCore.order
index a31461c..0fdabb1 100644
--- a/WebCore/WebCore.order
+++ b/WebCore/WebCore.order
@@ -162,8 +162,6 @@ __ZN7WebCore21ContextMenuControllerC1EPNS_4PageEPNS_17ContextMenuClientE
 __ZN7WebCore21ContextMenuControllerC2EPNS_4PageEPNS_17ContextMenuClientE
 __ZN7WebCore19InspectorControllerC1EPNS_4PageEPNS_15InspectorClientE
 __ZN7WebCore19InspectorControllerC2EPNS_4PageEPNS_15InspectorClientE
-__ZN7WebCore17InspectorCSSStoreC1Ev
-__ZN7WebCore17InspectorCSSStoreC2Ev
 __ZN7WebCore16InspectorBackendC1EPNS_19InspectorControllerE
 __ZN7WebCore16InspectorBackendC2EPNS_19InspectorControllerE
 __ZN7WebCore18InjectedScriptHostC1EPNS_19InspectorControllerE
diff --git a/WebCore/WebCore.pro b/WebCore/WebCore.pro
index ced4130..36dbeb1 100644
--- a/WebCore/WebCore.pro
+++ b/WebCore/WebCore.pro
@@ -1018,7 +1018,6 @@ SOURCES += \
     inspector/InspectorApplicationCacheAgent.cpp \
     inspector/InspectorBackend.cpp \
     inspector/InspectorCSSAgent.cpp \
-    inspector/InspectorCSSStore.cpp \
     inspector/InspectorClient.cpp \
     inspector/InspectorController.cpp \
     inspector/InspectorDatabaseResource.cpp \
diff --git a/WebCore/WebCore.vcproj/WebCore.vcproj b/WebCore/WebCore.vcproj/WebCore.vcproj
index 43e3e43..92cf42b 100755
--- a/WebCore/WebCore.vcproj/WebCore.vcproj
+++ b/WebCore/WebCore.vcproj/WebCore.vcproj
@@ -64650,14 +64650,6 @@
 				>
 			</File>
 			<File
-				RelativePath="..\inspector\InspectorCSSStore.cpp"
-				>
-			</File>
-			<File
-				RelativePath="..\inspector\InspectorCSSStore.h"
-				>
-			</File>
-			<File
 				RelativePath="..\inspector\InspectorDatabaseResource.cpp"
 				>
 			</File>
diff --git a/WebCore/WebCore.xcodeproj/project.pbxproj b/WebCore/WebCore.xcodeproj/project.pbxproj
index 64c0d6b..78604b0 100644
--- a/WebCore/WebCore.xcodeproj/project.pbxproj
+++ b/WebCore/WebCore.xcodeproj/project.pbxproj
@@ -1609,8 +1609,6 @@
 		82AB1774125C826700C5069D /* InspectorStyleSheet.h in Headers */ = {isa = PBXBuildFile; fileRef = 82AB1770125C826700C5069D /* InspectorStyleSheet.h */; };
 		82AB1775125C826700C5069D /* InspectorResourceAgent.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 82AB1771125C826700C5069D /* InspectorResourceAgent.cpp */; };
 		82AB1776125C826700C5069D /* InspectorResourceAgent.h in Headers */ = {isa = PBXBuildFile; fileRef = 82AB1772125C826700C5069D /* InspectorResourceAgent.h */; };
-		82B658981189E39200E052A1 /* InspectorCSSStore.h in Headers */ = {isa = PBXBuildFile; fileRef = 82B658971189E39200E052A1 /* InspectorCSSStore.h */; settings = {ATTRIBUTES = (Private, ); }; };
-		82B6589A1189E47600E052A1 /* InspectorCSSStore.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 82B658991189E47600E052A1 /* InspectorCSSStore.cpp */; };
 		82E3D8DE122EA0D1003AE5BC /* CSSPropertySourceData.cpp in Sources */ = {isa = PBXBuildFile; fileRef = 82E3D8DC122EA0D1003AE5BC /* CSSPropertySourceData.cpp */; };
 		82E3D8DF122EA0D1003AE5BC /* CSSPropertySourceData.h in Headers */ = {isa = PBXBuildFile; fileRef = 82E3D8DD122EA0D1003AE5BC /* CSSPropertySourceData.h */; settings = {ATTRIBUTES = (Private, ); }; };
 		8419D2A7120D92D000141F8F /* SVGPathByteStream.h in Headers */ = {isa = PBXBuildFile; fileRef = 8419D2A4120D92D000141F8F /* SVGPathByteStream.h */; };
@@ -7800,8 +7798,6 @@
 		82AB1770125C826700C5069D /* InspectorStyleSheet.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorStyleSheet.h; sourceTree = "<group>"; };
 		82AB1771125C826700C5069D /* InspectorResourceAgent.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InspectorResourceAgent.cpp; sourceTree = "<group>"; };
 		82AB1772125C826700C5069D /* InspectorResourceAgent.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorResourceAgent.h; sourceTree = "<group>"; };
-		82B658971189E39200E052A1 /* InspectorCSSStore.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = InspectorCSSStore.h; sourceTree = "<group>"; };
-		82B658991189E47600E052A1 /* InspectorCSSStore.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = InspectorCSSStore.cpp; sourceTree = "<group>"; };
 		82E3D8DC122EA0D1003AE5BC /* CSSPropertySourceData.cpp */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.cpp.cpp; path = CSSPropertySourceData.cpp; sourceTree = "<group>"; };
 		82E3D8DD122EA0D1003AE5BC /* CSSPropertySourceData.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = CSSPropertySourceData.h; sourceTree = "<group>"; };
 		8419D2A4120D92D000141F8F /* SVGPathByteStream.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SVGPathByteStream.h; sourceTree = "<group>"; };
@@ -12387,8 +12383,6 @@
 				1C81B9560E97330800266E07 /* InspectorController.h */,
 				82AB1741124B99EC00C5069D /* InspectorCSSAgent.cpp */,
 				82AB1742124B99EC00C5069D /* InspectorCSSAgent.h */,
-				82B658991189E47600E052A1 /* InspectorCSSStore.cpp */,
-				82B658971189E39200E052A1 /* InspectorCSSStore.h */,
 				41F062130F5F192600A07EAC /* InspectorDatabaseResource.cpp */,
 				41F062120F5F192600A07EAC /* InspectorDatabaseResource.h */,
 				F33F053B120B0DA500E5743A /* InspectorDebuggerAgent.cpp */,
@@ -19970,7 +19964,6 @@
 				1C81B95C0E97330800266E07 /* InspectorClient.h in Headers */,
 				1C81B95A0E97330800266E07 /* InspectorController.h in Headers */,
 				82AB1744124B99EC00C5069D /* InspectorCSSAgent.h in Headers */,
-				82B658981189E39200E052A1 /* InspectorCSSStore.h in Headers */,
 				41F062140F5F192600A07EAC /* InspectorDatabaseResource.h in Headers */,
 				F33F053E120B0DA500E5743A /* InspectorDebuggerAgent.h in Headers */,
 				7A24587C1021EAF4000A00AA /* InspectorDOMAgent.h in Headers */,
@@ -22599,7 +22592,6 @@
 				7A1F2B52126C61B20006A7E6 /* InspectorClient.cpp in Sources */,
 				1C81B95B0E97330800266E07 /* InspectorController.cpp in Sources */,
 				82AB1743124B99EC00C5069D /* InspectorCSSAgent.cpp in Sources */,
-				82B6589A1189E47600E052A1 /* InspectorCSSStore.cpp in Sources */,
 				41F062150F5F192600A07EAC /* InspectorDatabaseResource.cpp in Sources */,
 				F33F053D120B0DA500E5743A /* InspectorDebuggerAgent.cpp in Sources */,
 				7A24587B1021EAF4000A00AA /* InspectorDOMAgent.cpp in Sources */,
diff --git a/WebCore/inspector/Inspector.idl b/WebCore/inspector/Inspector.idl
index c185d2d..99b2fab 100644
--- a/WebCore/inspector/Inspector.idl
+++ b/WebCore/inspector/Inspector.idl
@@ -197,19 +197,6 @@ module core {
         [handler=Controller] void highlightFrame(in unsigned long frameId);
         [handler=Controller] void hideFrameHighlight();
 
-        [handler=DOM] void getStyles(in long nodeId, in boolean authOnly, out Value styles);
-        [handler=DOM] void getAllStyles(out Array styles);
-        [handler=DOM] void getInlineStyle(in long nodeId, out Value style);
-        [handler=DOM] void getComputedStyle(in long nodeId, out Value style);
-        [handler=DOM] void getStyleSheet(in long styleSheetId, out Object styleSheet);
-        [handler=DOM] void getStyleSourceData(in long styleSheetId, out Object styleSourceData);
-        [handler=DOM] void applyStyleText(in long styleId, in String styleText, in String propertyName, out boolean success, out Value style);
-        [handler=DOM] void setStyleText(in long styleId, in String styleText, out boolean success);
-        [handler=DOM] void setStyleProperty(in long styleId, in String name, in String value, out boolean success);
-        [handler=DOM] void toggleStyleEnabled(in long styleId, in String propertyName, in boolean disabled, out Value style);
-        [handler=DOM] void setRuleSelector(in long ruleId, in String selector, in long selectedNodeId, out Value rule, out boolean selectorAffectsNode);
-        [handler=DOM] void addRule(in String selector, in long selectedNodeId, out Value rule, out boolean selectorAffectsNode);
-
         [handler=CSS] void getStylesForNode2(in long nodeId, out Value styles);
         [handler=CSS] void getComputedStyleForNode2(in long nodeId, out Value style);
         [handler=CSS] void getInlineStyleForNode2(in long nodeId, out Value style);
diff --git a/WebCore/inspector/InspectorCSSAgent.h b/WebCore/inspector/InspectorCSSAgent.h
index 2d2efb5..f67d57d 100644
--- a/WebCore/inspector/InspectorCSSAgent.h
+++ b/WebCore/inspector/InspectorCSSAgent.h
@@ -46,6 +46,7 @@ class Element;
 class InspectorFrontend;
 class NameNodeMap;
 class Node;
+class StyleBase;
 
 #if ENABLE(INSPECTOR)
 
diff --git a/WebCore/inspector/InspectorCSSStore.cpp b/WebCore/inspector/InspectorCSSStore.cpp
deleted file mode 100644
index 08634cb..0000000
--- a/WebCore/inspector/InspectorCSSStore.cpp
+++ /dev/null
@@ -1,340 +0,0 @@
-/*
- * Copyright (C) 2010 Google Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1.  Redistributions of source code must retain the above copyright
- *     notice, this list of conditions and the following disclaimer.
- * 2.  Redistributions in binary form must reproduce the above copyright
- *     notice, this list of conditions and the following disclaimer in the
- *     documentation and/or other materials provided with the distribution.
- * 3.  Neither the name of Apple Computer, Inc. ("Apple") nor the names of
- *     its contributors may be used to endorse or promote products derived
- *     from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY
- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#include "config.h"
-#include "InspectorCSSStore.h"
-
-#if ENABLE(INSPECTOR)
-
-#include "CSSMutableStyleDeclaration.h"
-#include "CSSParser.h"
-#include "CSSRuleList.h"
-#include "CSSStyleDeclaration.h"
-#include "CSSStyleRule.h"
-#include "CSSStyleSheet.h"
-#include "CachedResource.h"
-#include "DocumentLoader.h"
-#include "Element.h"
-#include "Frame.h"
-#include "HTMLHeadElement.h"
-#include "InspectorController.h"
-#include "InspectorResourceAgent.h"
-#include "Node.h"
-#include "PlatformString.h"
-#include "SharedBuffer.h"
-#include "StyleSheetList.h"
-#include "TextEncoding.h"
-
-namespace WebCore {
-
-InspectorCSSStore::InspectorCSSStore(InspectorController* inspectorController)
-    : m_inspectorController(inspectorController)
-    , m_lastStyleId(1)
-    , m_lastStyleSheetId(1)
-    , m_lastRuleId(1)
-{
-}
-
-InspectorCSSStore::~InspectorCSSStore()
-{
-}
-
-void InspectorCSSStore::reset()
-{
-    m_styleToId.clear();
-    m_idToStyle.clear();
-    m_ruleToId.clear();
-    m_idToRule.clear();
-    deleteAllValues(m_styleSheetToOffsets);
-    m_styleSheetToOffsets.clear();
-    m_styleSheetToId.clear();
-    m_idToStyleSheet.clear();
-    m_idToStyleSheetText.clear();
-    m_idToDisabledStyle.clear();
-    m_documentNodeToInspectorStyleSheetMap.clear();
-
-    m_lastStyleId = 1;
-    m_lastStyleSheetId = 1;
-    m_lastRuleId = 1;
-}
-
-void InspectorCSSStore::removeDocument(Document* doc)
-{
-    m_documentNodeToInspectorStyleSheetMap.remove(doc);
-}
-
-CSSStyleSheet* InspectorCSSStore::inspectorStyleSheet(Document* ownerDocument, bool createIfAbsent)
-{
-    DocumentToStyleSheetMap::iterator it = m_documentNodeToInspectorStyleSheetMap.find(ownerDocument);
-    if (it != m_documentNodeToInspectorStyleSheetMap.end())
-        return it->second.get();
-    if (!createIfAbsent)
-        return 0;
-    ExceptionCode ec = 0;
-    RefPtr<Element> styleElement = ownerDocument->createElement("style", ec);
-    if (!ec)
-        styleElement->setAttribute("type", "text/css", ec);
-    if (!ec)
-        ownerDocument->head()->appendChild(styleElement, ec);
-    if (ec)
-        return 0;
-    StyleSheetList* styleSheets = ownerDocument->styleSheets();
-    StyleSheet* styleSheet = styleSheets->item(styleSheets->length() - 1);
-    if (!styleSheet->isCSSStyleSheet())
-        return 0;
-    CSSStyleSheet* inspectorStyleSheet = static_cast<CSSStyleSheet*>(styleSheet);
-    m_documentNodeToInspectorStyleSheetMap.set(ownerDocument, inspectorStyleSheet);
-    return inspectorStyleSheet;
-}
-
-String InspectorCSSStore::styleSheetText(long styleSheetId)
-{
-    IdToStyleSheetTextMap::iterator it = m_idToStyleSheetText.find(styleSheetId);
-    if (it != m_idToStyleSheetText.end())
-        return it->second;
-
-    CSSStyleSheet* styleSheet = styleSheetForId(styleSheetId);
-    if (!styleSheet)
-        return String();
-
-    String result;
-    bool success = false;
-    Node* ownerNode = styleSheet->ownerNode();
-    if (ownerNode && ownerNode->nodeType() == Node::ELEMENT_NODE) {
-        Element* ownerElement = static_cast<Element*>(ownerNode);
-        if (ownerElement->tagName().lower() == "style") {
-            result = inlineStyleSheetText(styleSheet);
-            success = true;
-        }
-    }
-    if (!success)
-        success = resourceStyleSheetText(styleSheet, &result);
-
-    if (success)
-        m_idToStyleSheetText.set(styleSheetId, result);
-    return result;
-}
-
-bool InspectorCSSStore::resourceStyleSheetText(CSSStyleSheet* styleSheet, String* result)
-{
-    return InspectorResourceAgent::resourceContent(styleSheet->document()->frame(), styleSheet->finalURL(), result);
-}
-
-String InspectorCSSStore::inlineStyleSheetText(CSSStyleSheet* styleSheet)
-{
-    Node* ownerNode = styleSheet->ownerNode();
-    if (!ownerNode || ownerNode->nodeType() != Node::ELEMENT_NODE || m_styleSheetToId.find(styleSheet) == m_styleSheetToId.end())
-        return String();
-    Element* ownerElement = static_cast<Element*>(ownerNode);
-    if (ownerElement->tagName().lower() != "style")
-        return String();
-    return ownerElement->innerText();
-}
-
-
-// All ranges are: [start; end) (start - inclusive, end - exclusive).
-bool InspectorCSSStore::getRuleSourceData(CSSStyleDeclaration* style, RefPtr<CSSRuleSourceData>* result)
-{
-    if (!style)
-        return false;
-
-    Element* element = inlineStyleElement(style);
-    if (element) {
-        // Inline: style="...".
-        RefPtr<CSSRuleSourceData> ruleSourceData = CSSRuleSourceData::create();
-        RefPtr<CSSStyleSourceData> styleSourceData = CSSStyleSourceData::create();
-        bool success = getStyleAttributeRanges(element, &styleSourceData);
-        if (!success)
-            return false;
-        ruleSourceData->styleSourceData = styleSourceData.release();
-        *result = ruleSourceData;
-        return true;
-    }
-
-    CSSStyleSheet* styleSheet = getParentStyleSheet(style);
-    if (!styleSheet)
-        return false;
-
-    Vector<RefPtr<CSSRuleSourceData> >* rangesVector = 0;
-    StyleSheetToOffsetsMap::iterator it = m_styleSheetToOffsets.find(styleSheet);
-    if (it == m_styleSheetToOffsets.end()) {
-        String text = styleSheetText(bindStyleSheet(styleSheet));
-        if (!text.isEmpty()) {
-            RefPtr<CSSStyleSheet> newStyleSheet = CSSStyleSheet::create(styleSheet->ownerNode());
-            CSSParser p;
-            StyleRuleRangeMap ruleRangeMap;
-            p.parseSheet(newStyleSheet.get(), text, 0, &ruleRangeMap);
-            rangesVector = new Vector<RefPtr<CSSRuleSourceData> >;
-            extractRanges(newStyleSheet.get(), ruleRangeMap, rangesVector);
-            m_styleSheetToOffsets.set(styleSheet, rangesVector);
-        }
-    } else
-        rangesVector = it->second;
-    if (!rangesVector)
-        return false;
-
-    unsigned ruleIndex = 0;
-    for (unsigned i = 0, length = styleSheet->length(); i < length; ++i) {
-        CSSStyleRule* rule = asCSSStyleRule(styleSheet->item(i));
-        if (!rule)
-            continue;
-        if (rule->style() == style) {
-            ASSERT(ruleIndex < rangesVector->size());
-            *result = rangesVector->at(ruleIndex);
-            return true;
-        }
-        ruleIndex++;
-    }
-    return false;
-}
-
-void InspectorCSSStore::extractRanges(CSSStyleSheet* styleSheet, const StyleRuleRangeMap& ruleRangeMap, Vector<RefPtr<CSSRuleSourceData> >* rangesVector)
-{
-    for (unsigned i = 0, length = styleSheet->length(); i < length; ++i) {
-        CSSStyleRule* rule = asCSSStyleRule(styleSheet->item(i));
-        if (!rule)
-            continue;
-        StyleRuleRangeMap::const_iterator it = ruleRangeMap.find(rule);
-        if (it != ruleRangeMap.end())
-            rangesVector->append(it->second);
-    }
-}
-
-bool InspectorCSSStore::getStyleAttributeRanges(Node* node, RefPtr<CSSStyleSourceData>* result)
-{
-    if (!node || !node->isStyledElement())
-        return false;
-
-    String styleText = static_cast<StyledElement*>(node)->getAttribute("style");
-    if (styleText.isEmpty()) {
-        (*result)->styleBodyRange.start = 0;
-        (*result)->styleBodyRange.end = 0;
-        return true;
-    }
-
-    RefPtr<CSSMutableStyleDeclaration> tempDeclaration = CSSMutableStyleDeclaration::create();
-    CSSParser p;
-    p.parseDeclaration(tempDeclaration.get(), styleText, result);
-    return true;
-}
-
-CSSStyleSheet* InspectorCSSStore::getParentStyleSheet(CSSStyleDeclaration* style)
-{
-    if (!style)
-        return 0;
-
-    StyleSheet* styleSheet = style->stylesheet();
-    if (styleSheet && styleSheet->isCSSStyleSheet())
-        return static_cast<CSSStyleSheet*>(styleSheet);
-
-    return 0;
-}
-
-CSSStyleRule* InspectorCSSStore::asCSSStyleRule(StyleBase* styleBase)
-{
-    if (!styleBase->isStyleRule())
-        return 0;
-    CSSRule* rule = static_cast<CSSRule*>(styleBase);
-    if (rule->type() != CSSRule::STYLE_RULE)
-        return 0;
-    return static_cast<CSSStyleRule*>(rule);
-}
-
-DisabledStyleDeclaration* InspectorCSSStore::disabledStyleForId(long styleId, bool createIfAbsent)
-{
-    IdToDisabledStyleMap::iterator it = m_idToDisabledStyle.find(styleId);
-    if (it == m_idToDisabledStyle.end() && createIfAbsent)
-        it = m_idToDisabledStyle.set(styleId, DisabledStyleDeclaration()).first;
-    return it == m_idToDisabledStyle.end() ? 0 : &(it->second);
-}
-
-CSSStyleDeclaration* InspectorCSSStore::styleForId(long styleId)
-{
-    IdToStyleMap::iterator it = m_idToStyle.find(styleId);
-    return it == m_idToStyle.end() ? 0 : it->second.get();
-}
-
-CSSStyleSheet* InspectorCSSStore::styleSheetForId(long styleSheetId)
-{
-    IdToStyleSheetMap::iterator it = m_idToStyleSheet.find(styleSheetId);
-    return it == m_idToStyleSheet.end() ? 0 : it->second.get();
-}
-
-CSSStyleRule* InspectorCSSStore::ruleForId(long ruleId)
-{
-    IdToRuleMap::iterator it = m_idToRule.find(ruleId);
-    return it == m_idToRule.end() ? 0 : it->second.get();
-}
-
-long InspectorCSSStore::bindStyle(CSSStyleDeclaration* style)
-{
-    long id = m_styleToId.get(style);
-    if (!id) {
-        id = m_lastStyleId++;
-        m_idToStyle.set(id, style);
-        m_styleToId.set(style, id);
-    }
-    return id;
-}
-
-long InspectorCSSStore::bindStyleSheet(CSSStyleSheet* styleSheet)
-{
-    long id = m_styleSheetToId.get(styleSheet);
-    if (!id) {
-        id = m_lastStyleSheetId++;
-        m_idToStyleSheet.set(id, styleSheet);
-        m_styleSheetToId.set(styleSheet, id);
-    }
-    return id;
-}
-
-long InspectorCSSStore::bindRule(CSSStyleRule* rule)
-{
-    long id = m_ruleToId.get(rule);
-    if (!id) {
-        id = m_lastRuleId++;
-        m_idToRule.set(id, rule);
-        m_ruleToId.set(rule, id);
-    }
-    return id;
-}
-
-// static
-Element* InspectorCSSStore::inlineStyleElement(CSSStyleDeclaration* style)
-{
-    if (!style || !style->isMutableStyleDeclaration())
-        return 0;
-    Node* node = static_cast<CSSMutableStyleDeclaration*>(style)->node();
-    if (!node || !node->isStyledElement() || static_cast<StyledElement*>(node)->getInlineStyleDecl() != style)
-        return 0;
-    return static_cast<Element*>(node);
-}
-
-} // namespace WebCore
-
-#endif // ENABLE(INSPECTOR)
diff --git a/WebCore/inspector/InspectorCSSStore.h b/WebCore/inspector/InspectorCSSStore.h
deleted file mode 100644
index 0414b58..0000000
--- a/WebCore/inspector/InspectorCSSStore.h
+++ /dev/null
@@ -1,113 +0,0 @@
-/*
- * Copyright (C) 2010 Google Inc. All rights reserved.
- *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- *
- * 1.  Redistributions of source code must retain the above copyright
- *     notice, this list of conditions and the following disclaimer.
- * 2.  Redistributions in binary form must reproduce the above copyright
- *     notice, this list of conditions and the following disclaimer in the
- *     documentation and/or other materials provided with the distribution.
- * 3.  Neither the name of Apple Computer, Inc. ("Apple") nor the names of
- *     its contributors may be used to endorse or promote products derived
- *     from this software without specific prior written permission.
- *
- * THIS SOFTWARE IS PROVIDED BY APPLE AND ITS CONTRIBUTORS "AS IS" AND ANY
- * EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
- * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
- * DISCLAIMED. IN NO EVENT SHALL APPLE OR ITS CONTRIBUTORS BE LIABLE FOR ANY
- * DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
- * (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
- * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- * ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
- */
-
-#ifndef InspectorCSSStore_h
-#define InspectorCSSStore_h
-
-#include "CSSPropertySourceData.h"
-#include "MemoryCache.h"
-
-#include <wtf/Forward.h>
-#include <wtf/HashMap.h>
-#include <wtf/RefPtr.h>
-
-namespace WebCore {
-
-class CSSMutableStyleDeclaration;
-class CSSStyleDeclaration;
-class CSSRuleList;
-class CSSStyleRule;
-class CSSStyleSheet;
-class Document;
-class Element;
-class InspectorController;
-class Node;
-class StyleBase;
-
-typedef std::pair<String, String> PropertyValueAndPriority;
-typedef HashMap<String, PropertyValueAndPriority> DisabledStyleDeclaration;
-typedef HashMap<CSSStyleDeclaration*, long> StyleToIdMap;
-typedef HashMap<long, RefPtr<CSSStyleDeclaration> > IdToStyleMap;
-typedef HashMap<CSSStyleRule*, long> RuleToIdMap;
-typedef HashMap<long, RefPtr<CSSStyleRule> > IdToRuleMap;
-typedef HashMap<CSSStyleSheet*, Vector<RefPtr<CSSRuleSourceData> >* > StyleSheetToOffsetsMap;
-typedef HashMap<CSSStyleSheet*, long> StyleSheetToIdMap;
-typedef HashMap<long, RefPtr<CSSStyleSheet> > IdToStyleSheetMap;
-typedef HashMap<long, String> IdToStyleSheetTextMap;
-typedef HashMap<long, DisabledStyleDeclaration> IdToDisabledStyleMap;
-typedef HashMap<RefPtr<Document>, RefPtr<CSSStyleSheet> > DocumentToStyleSheetMap;
-
-class InspectorCSSStore {
-
-public:
-    static CSSStyleSheet* getParentStyleSheet(CSSStyleDeclaration*);
-    static Element* inlineStyleElement(CSSStyleDeclaration*);
-
-    InspectorCSSStore(InspectorController* inspectorController);
-    ~InspectorCSSStore();
-    void reset();
-    bool getRuleSourceData(CSSStyleDeclaration*, RefPtr<CSSRuleSourceData>* result);
-    CSSStyleDeclaration* styleForId(long styleId);
-    CSSStyleSheet* styleSheetForId(long styleSheetId);
-    CSSStyleRule* ruleForId(long styleRuleId);
-    DisabledStyleDeclaration* disabledStyleForId(long styleId, bool createIfAbsent);
-    String styleSheetText(long styleSheetId);
-    CSSStyleSheet* inspectorStyleSheet(Document* ownerDocument, bool createIfAbsent);
-    void removeDocument(Document*);
-
-    long bindRule(CSSStyleRule* rule);
-    long bindStyle(CSSStyleDeclaration* style);
-    long bindStyleSheet(CSSStyleSheet* styleSheet);
-
-private:
-    static CSSStyleRule* asCSSStyleRule(StyleBase*);
-    String inlineStyleSheetText(CSSStyleSheet*);
-    bool resourceStyleSheetText(CSSStyleSheet*, String* result);
-    void extractRanges(CSSStyleSheet*, const StyleRuleRangeMap&, Vector<RefPtr<CSSRuleSourceData> >* rangesVector);
-    bool getStyleAttributeRanges(Node* parentNode, RefPtr<CSSStyleSourceData>* result);
-
-    StyleToIdMap m_styleToId;
-    IdToStyleMap m_idToStyle;
-    RuleToIdMap m_ruleToId;
-    IdToRuleMap m_idToRule;
-    StyleSheetToOffsetsMap m_styleSheetToOffsets;
-    StyleSheetToIdMap m_styleSheetToId;
-    IdToDisabledStyleMap m_idToDisabledStyle;
-    IdToStyleSheetMap m_idToStyleSheet;
-    IdToStyleSheetTextMap m_idToStyleSheetText;
-    DocumentToStyleSheetMap m_documentNodeToInspectorStyleSheetMap;
-
-    InspectorController* m_inspectorController;
-    long m_lastStyleId;
-    long m_lastStyleSheetId;
-    long m_lastRuleId;
-};
-
-} // namespace WebCore
-
-#endif // !defined(InspectorCSSStore_h)
diff --git a/WebCore/inspector/InspectorController.cpp b/WebCore/inspector/InspectorController.cpp
index ed319f3..9b45bbe 100644
--- a/WebCore/inspector/InspectorController.cpp
+++ b/WebCore/inspector/InspectorController.cpp
@@ -59,7 +59,6 @@
 #include "InspectorBackend.h"
 #include "InspectorBackendDispatcher.h"
 #include "InspectorCSSAgent.h"
-#include "InspectorCSSStore.h"
 #include "InspectorClient.h"
 #include "InspectorDOMAgent.h"
 #include "InspectorDOMStorageResource.h"
@@ -144,7 +143,6 @@ InspectorController::InspectorController(Page* page, InspectorClient* client)
     , m_client(client)
     , m_openingFrontend(false)
     , m_cssAgent(new InspectorCSSAgent())
-    , m_cssStore(new InspectorCSSStore(this))
     , m_mainResourceIdentifier(0)
     , m_expiredConsoleMessageCount(0)
     , m_groupLevel(0)
@@ -484,7 +482,7 @@ void InspectorController::connectFrontend()
     m_openingFrontend = false;
     releaseFrontendLifetimeAgents();
     m_frontend = new InspectorFrontend(m_client);
-    m_domAgent = InspectorDOMAgent::create(m_cssStore.get(), m_frontend.get());
+    m_domAgent = InspectorDOMAgent::create(m_frontend.get());
     m_resourceAgent = InspectorResourceAgent::create(m_inspectedPage, m_frontend.get());
 
     m_cssAgent->setDOMAgent(m_domAgent.get());
@@ -747,7 +745,6 @@ void InspectorController::didCommitLoad(DocumentLoader* loader)
         // resources are cleared so that it has a chance to unbind them.
         unbindAllResources();
 
-        m_cssStore->reset();
         if (m_frontend) {
             m_frontend->reset();
             m_domAgent->reset();
diff --git a/WebCore/inspector/InspectorController.h b/WebCore/inspector/InspectorController.h
index 5b407e0..e57c089 100644
--- a/WebCore/inspector/InspectorController.h
+++ b/WebCore/inspector/InspectorController.h
@@ -59,7 +59,6 @@ class InspectorBackend;
 class InspectorBackendDispatcher;
 class InspectorClient;
 class InspectorCSSAgent;
-class InspectorCSSStore;
 class InspectorDOMAgent;
 class InspectorDOMStorageResource;
 class InspectorDatabaseResource;
@@ -345,7 +344,6 @@ private:
     OwnPtr<InspectorCSSAgent> m_cssAgent;
     RefPtr<InspectorDOMAgent> m_domAgent;
     RefPtr<InspectorStorageAgent> m_storageAgent;
-    OwnPtr<InspectorCSSStore> m_cssStore;
     OwnPtr<InspectorTimelineAgent> m_timelineAgent;
     OwnPtr<InspectorState> m_state;
 
diff --git a/WebCore/inspector/InspectorDOMAgent.cpp b/WebCore/inspector/InspectorDOMAgent.cpp
index 894e4b2..29715b4 100644
--- a/WebCore/inspector/InspectorDOMAgent.cpp
+++ b/WebCore/inspector/InspectorDOMAgent.cpp
@@ -216,9 +216,8 @@ const int domBreakpointDerivedTypeShift = 16;
 
 }
 
-InspectorDOMAgent::InspectorDOMAgent(InspectorCSSStore* cssStore, InspectorFrontend* frontend)
+InspectorDOMAgent::InspectorDOMAgent(InspectorFrontend* frontend)
     : EventListener(InspectorDOMAgentType)
-    , m_cssStore(cssStore)
     , m_frontend(frontend)
     , m_domListener(0)
     , m_lastNodeId(1)
@@ -339,7 +338,6 @@ void InspectorDOMAgent::unbind(Node* node, NodeToIdMap* nodesMap)
         stopListening(frameOwner->contentDocument());
         if (m_domListener)
             m_domListener->didRemoveDocument(frameOwner->contentDocument());
-        cssStore()->removeDocument(frameOwner->contentDocument());
     }
 
     long id = nodesMap->get(node);
@@ -1201,532 +1199,6 @@ String InspectorDOMAgent::createBreakpointId(long nodeId, long type)
     return makeString("dom:", String::number(nodeId), ':', String::number(type));
 }
 
-void InspectorDOMAgent::getStyles(long nodeId, bool authorOnly, RefPtr<InspectorValue>* styles)
-{
-    Node* node = nodeForId(nodeId);
-    if (!node || node->nodeType() != Node::ELEMENT_NODE)
-        return;
-
-    DOMWindow* defaultView = node->ownerDocument()->defaultView();
-    if (!defaultView)
-        return;
-
-    Element* element = static_cast<Element*>(node);
-    RefPtr<CSSComputedStyleDeclaration> computedStyleInfo = computedStyle(node, true); // Support the viewing of :visited information in computed style.
-
-    RefPtr<InspectorObject> result = InspectorObject::create();
-    if (element->style())
-        result->setObject("inlineStyle", buildObjectForStyle(element->style(), true));
-    result->setObject("computedStyle", buildObjectForStyle(computedStyleInfo.get(), false));
-
-    CSSStyleSelector* selector = element->ownerDocument()->styleSelector();
-    RefPtr<CSSRuleList> matchedRules = selector->styleRulesForElement(element, authorOnly, true);
-    result->setArray("matchedCSSRules", buildArrayForCSSRules(node->ownerDocument(), matchedRules.get()));
-
-    result->setObject("styleAttributes", buildObjectForAttributeStyles(element));
-    result->setArray("pseudoElements", buildArrayForPseudoElements(element, authorOnly));
-
-    RefPtr<InspectorArray> inheritedStyles = InspectorArray::create();
-    Element* parentElement = element->parentElement();
-    while (parentElement) {
-        RefPtr<InspectorObject> parentStyle = InspectorObject::create();
-        inheritedStyles->pushObject(parentStyle);
-        if (parentElement->style() && parentElement->style()->length())
-            parentStyle->setObject("inlineStyle", buildObjectForStyle(parentElement->style(), true));
-
-        CSSStyleSelector* parentSelector = parentElement->ownerDocument()->styleSelector();
-        RefPtr<CSSRuleList> parentMatchedRules = parentSelector->styleRulesForElement(parentElement, authorOnly, true);
-        parentStyle->setArray("matchedCSSRules", buildArrayForCSSRules(parentElement->ownerDocument(), parentMatchedRules.get()));
-
-        parentElement = parentElement->parentElement();
-    }
-    result->setArray("inherited", inheritedStyles);
-    *styles = result.release();
-}
-
-void InspectorDOMAgent::getAllStyles(RefPtr<InspectorArray>* styles)
-{
-    for (ListHashSet<RefPtr<Document> >::iterator it = m_documents.begin(); it != m_documents.end(); ++it) {
-        StyleSheetList* list = (*it)->styleSheets();
-        for (unsigned i = 0; i < list->length(); ++i) {
-            StyleSheet* styleSheet = list->item(i);
-            if (styleSheet->isCSSStyleSheet())
-                (*styles)->pushObject(buildObjectForStyleSheet((*it).get(), static_cast<CSSStyleSheet*>(styleSheet)));
-        }
-    }
-}
-
-void InspectorDOMAgent::getStyleSheet(long styleSheetId, RefPtr<InspectorObject>* styleSheetObject)
-{
-    CSSStyleSheet* styleSheet = cssStore()->styleSheetForId(styleSheetId);
-    if (styleSheet && styleSheet->document())
-        *styleSheetObject = buildObjectForStyleSheet(styleSheet->document(), styleSheet);
-}
-
-void InspectorDOMAgent::getStyleSourceData(long styleId, RefPtr<InspectorObject>* dataObject)
-{
-    CSSStyleDeclaration* style = cssStore()->styleForId(styleId);
-    if (!style)
-        return;
-    RefPtr<CSSRuleSourceData> sourceData = CSSRuleSourceData::create();
-    bool success = cssStore()->getRuleSourceData(style, &sourceData);
-    if (!success)
-        return;
-    RefPtr<InspectorObject> result = InspectorObject::create();
-
-    RefPtr<InspectorObject> bodyRange = InspectorObject::create();
-    result->setObject("bodyRange", bodyRange);
-    bodyRange->setNumber("start", sourceData->styleSourceData->styleBodyRange.start);
-    bodyRange->setNumber("end", sourceData->styleSourceData->styleBodyRange.end);
-
-    RefPtr<InspectorObject> selectorRange = InspectorObject::create();
-    result->setObject("selectorRange", selectorRange);
-    selectorRange->setNumber("start", sourceData->selectorListRange.start);
-    selectorRange->setNumber("end", sourceData->selectorListRange.end);
-
-    RefPtr<InspectorArray> propertyRanges = InspectorArray::create();
-    result->setArray("propertyData", propertyRanges);
-    Vector<CSSPropertySourceData>& propertyData = sourceData->styleSourceData->propertyData;
-    for (Vector<CSSPropertySourceData>::iterator it = propertyData.begin(); it != propertyData.end(); ++it) {
-        RefPtr<InspectorObject> propertyRange = InspectorObject::create();
-        propertyRange->setString("name", it->name);
-        propertyRange->setString("value", it->value);
-        propertyRange->setBoolean("important", it->important);
-        propertyRange->setBoolean("parsed", it->parsedOk);
-        propertyRange->setNumber("start", it->range.start);
-        propertyRange->setNumber("end", it->range.end);
-        propertyRanges->pushObject(propertyRange);
-    }
-    *dataObject = result.release();
-}
-
-void InspectorDOMAgent::getInlineStyle(long nodeId, RefPtr<InspectorValue>* style)
-{
-    Node* node = nodeForId(nodeId);
-    if (!node || node->nodeType() != Node::ELEMENT_NODE)
-        return;
-    *style = buildObjectForStyle(static_cast<Element*>(node)->style(), true);
-}
-
-void InspectorDOMAgent::getComputedStyle(long nodeId, RefPtr<InspectorValue>* style)
-{
-    Node* node = nodeForId(nodeId);
-    if (!node || node->nodeType() != Node::ELEMENT_NODE)
-        return;
-
-    DOMWindow* defaultView = node->ownerDocument()->defaultView();
-    if (!defaultView)
-        return;
-
-    Element* element = static_cast<Element*>(node);
-    *style = buildObjectForStyle(defaultView->getComputedStyle(element, "").get(), false);
-}
-
-PassRefPtr<InspectorObject> InspectorDOMAgent::buildObjectForAttributeStyles(Element* element)
-{
-    RefPtr<InspectorObject> styleAttributes = InspectorObject::create();
-    NamedNodeMap* attributes = element->attributes();
-    for (unsigned i = 0; attributes && i < attributes->length(); ++i) {
-        Attribute* attribute = attributes->attributeItem(i);
-        if (attribute->style()) {
-            String attributeName = attribute->localName();
-            styleAttributes->setObject(attributeName.utf8().data(), buildObjectForStyle(attribute->style(), true));
-        }
-    }
-    return styleAttributes;
-}
-
-PassRefPtr<InspectorArray> InspectorDOMAgent::buildArrayForCSSRules(Document* ownerDocument, CSSRuleList* matchedRules)
-{
-    RefPtr<InspectorArray> matchedCSSRules = InspectorArray::create();
-    for (unsigned i = 0; matchedRules && i < matchedRules->length(); ++i) {
-        CSSRule* rule = matchedRules->item(i);
-        if (rule->type() == CSSRule::STYLE_RULE)
-            matchedCSSRules->pushObject(buildObjectForRule(ownerDocument, static_cast<CSSStyleRule*>(rule)));
-    }
-    return matchedCSSRules.release();
-}
-
-PassRefPtr<InspectorArray> InspectorDOMAgent::buildArrayForPseudoElements(Element* element, bool authorOnly)
-{
-    RefPtr<InspectorArray> result = InspectorArray::create();
-    CSSStyleSelector* selector = element->ownerDocument()->styleSelector();
-    RefPtr<RenderStyle> renderStyle = element->styleForRenderer();
-
-    for (PseudoId pseudoId = FIRST_PUBLIC_PSEUDOID; pseudoId < AFTER_LAST_INTERNAL_PSEUDOID; pseudoId = static_cast<PseudoId>(pseudoId + 1)) {
-        RefPtr<CSSRuleList> matchedRules = selector->pseudoStyleRulesForElement(element, pseudoId, authorOnly, true);
-        if (matchedRules && matchedRules->length()) {
-            RefPtr<InspectorObject> pseudoStyles = InspectorObject::create();
-            pseudoStyles->setNumber("pseudoId", static_cast<int>(pseudoId));
-            pseudoStyles->setArray("rules", buildArrayForCSSRules(element->ownerDocument(), matchedRules.get()));
-            result->pushObject(pseudoStyles.release());
-        }
-    }
-    return result.release();
-}
-
-void InspectorDOMAgent::applyStyleText(long styleId, const String& styleText, const String& propertyName, bool* success, RefPtr<InspectorValue>* styleObject)
-{
-    CSSStyleDeclaration* style = cssStore()->styleForId(styleId);
-    if (!style)
-        return;
-
-    // Remove disabled property entry for property with given name.
-    DisabledStyleDeclaration* disabledStyle = cssStore()->disabledStyleForId(styleId, false);
-    if (disabledStyle)
-        disabledStyle->remove(propertyName);
-
-    int styleTextLength = styleText.length();
-
-    RefPtr<CSSMutableStyleDeclaration> tempMutableStyle = CSSMutableStyleDeclaration::create();
-    tempMutableStyle->parseDeclaration(styleText);
-    CSSStyleDeclaration* tempStyle = static_cast<CSSStyleDeclaration*>(tempMutableStyle.get());
-
-    if (tempStyle->length() || !styleTextLength) {
-        ExceptionCode ec = 0;
-        // The input was parsable or the user deleted everything, so remove the
-        // original property from the real style declaration. If this represents
-        // a shorthand remove all the longhand properties.
-        if (style->getPropertyShorthand(propertyName).isEmpty()) {
-            Vector<String> longhandProps = longhandProperties(style, propertyName);
-            for (unsigned i = 0; !ec && i < longhandProps.size(); ++i)
-                style->removeProperty(longhandProps[i], ec);
-        }
-        // Explicitly delete properties with no shorthands as well as shorthands themselves.
-        if (!ec)
-            style->removeProperty(propertyName, ec);
-
-        if (ec)
-            return;
-    }
-
-    // Notify caller that the property was successfully deleted.
-    if (!styleTextLength) {
-        *success = true;
-        *styleObject = buildObjectForStyle(style, true);
-        return;
-    }
-
-    if (!tempStyle->length())
-        return;
-
-    // Iterate of the properties on the test element's style declaration and
-    // add them to the real style declaration. We take care to move shorthands.
-    HashSet<String> foundShorthands;
-
-    for (unsigned i = 0; i < tempStyle->length(); ++i) {
-        String name = tempStyle->item(i);
-        String shorthand = tempStyle->getPropertyShorthand(name);
-
-        if (!shorthand.isEmpty() && foundShorthands.contains(shorthand))
-            continue;
-
-        String value;
-        String priority;
-        if (!shorthand.isEmpty()) {
-            value = shorthandValue(tempStyle, shorthand);
-            priority = shorthandPriority(tempStyle, shorthand);
-            foundShorthands.add(shorthand);
-            name = shorthand;
-        } else {
-            value = tempStyle->getPropertyValue(name);
-            priority = tempStyle->getPropertyPriority(name);
-        }
-
-        // Set the property on the real style declaration.
-        ExceptionCode ec = 0;
-        style->setProperty(name, value, priority, ec);
-        // Remove disabled property entry for property with this name.
-        if (disabledStyle)
-            disabledStyle->remove(name);
-    }
-    *success = true;
-    *styleObject = buildObjectForStyle(style, true);
-}
-
-void InspectorDOMAgent::setStyleText(long styleId, const String& cssText, bool* success)
-{
-    CSSStyleDeclaration* style = cssStore()->styleForId(styleId);
-    if (!style)
-        return;
-    ExceptionCode ec = 0;
-    style->setCssText(cssText, ec);
-    *success = !ec;
-}
-
-void InspectorDOMAgent::setStyleProperty(long styleId, const String& name, const String& value, bool* success)
-{
-    CSSStyleDeclaration* style = cssStore()->styleForId(styleId);
-    if (!style)
-        return;
-
-    ExceptionCode ec = 0;
-    style->setProperty(name, value, ec);
-    *success = !ec;
-}
-
-void InspectorDOMAgent::toggleStyleEnabled(long styleId, const String& propertyName, bool disabled, RefPtr<InspectorValue>* styleObject)
-{
-    CSSStyleDeclaration* style = cssStore()->styleForId(styleId);
-    if (!style)
-        return;
-
-    DisabledStyleDeclaration* disabledStyle = cssStore()->disabledStyleForId(styleId, true);
-
-    // TODO: make sure this works with shorthands right.
-    ExceptionCode ec = 0;
-    if (disabled) {
-        disabledStyle->set(propertyName, std::make_pair(style->getPropertyValue(propertyName), style->getPropertyPriority(propertyName)));
-        if (!ec)
-            style->removeProperty(propertyName, ec);
-    } else if (disabledStyle->contains(propertyName)) {
-        PropertyValueAndPriority valueAndPriority = disabledStyle->get(propertyName);
-        style->setProperty(propertyName, valueAndPriority.first, valueAndPriority.second, ec);
-        if (!ec)
-            disabledStyle->remove(propertyName);
-    }
-    if (ec)
-        return;
-    *styleObject = buildObjectForStyle(style, true);
-}
-
-void InspectorDOMAgent::setRuleSelector(long ruleId, const String& selector, long selectedNodeId, RefPtr<InspectorValue>* ruleObject, bool* selectorAffectsNode)
-{
-    CSSStyleRule* rule = cssStore()->ruleForId(ruleId);
-    if (!rule)
-        return;
-
-    Node* node = nodeForId(selectedNodeId);
-
-    CSSStyleSheet* styleSheet = rule->parentStyleSheet();
-    ExceptionCode ec = 0;
-    styleSheet->addRule(selector, rule->style()->cssText(), ec);
-    if (ec)
-        return;
-
-    CSSStyleRule* newRule = static_cast<CSSStyleRule*>(styleSheet->item(styleSheet->length() - 1));
-    for (unsigned i = 0; i < styleSheet->length(); ++i) {
-        if (styleSheet->item(i) == rule) {
-            styleSheet->deleteRule(i, ec);
-            break;
-        }
-    }
-
-    if (ec)
-        return;
-
-    *selectorAffectsNode = ruleAffectsNode(newRule, node);
-    *ruleObject = buildObjectForRule(node->ownerDocument(), newRule);
-}
-
-void InspectorDOMAgent::addRule(const String& selector, long selectedNodeId, RefPtr<InspectorValue>* ruleObject, bool* selectorAffectsNode)
-{
-    Node* node = nodeForId(selectedNodeId);
-    if (!node)
-        return;
-
-    CSSStyleSheet* styleSheet = cssStore()->inspectorStyleSheet(node->ownerDocument(), true);
-    if (!styleSheet)
-        return; // could not add a stylesheet to the ownerDocument
-
-    ExceptionCode ec = 0;
-    styleSheet->addRule(selector, "", ec);
-    if (ec)
-        return;
-
-    CSSStyleRule* newRule = static_cast<CSSStyleRule*>(styleSheet->item(styleSheet->length() - 1));
-    *selectorAffectsNode = ruleAffectsNode(newRule, node);
-    *ruleObject = buildObjectForRule(node->ownerDocument(), newRule);
-}
-
-PassRefPtr<InspectorObject> InspectorDOMAgent::buildObjectForStyle(CSSStyleDeclaration* style, bool bind)
-{
-    RefPtr<InspectorObject> result = InspectorObject::create();
-    if (bind) {
-        result->setNumber("styleId", cssStore()->bindStyle(style));
-        CSSStyleSheet* styleSheet = InspectorCSSStore::getParentStyleSheet(style);
-        if (styleSheet)
-            result->setNumber("styleSheetId", cssStore()->bindStyleSheet(styleSheet));
-    }
-    RefPtr<InspectorObject> properties = InspectorObject::create();
-    properties->setString("width", style->getPropertyValue("width"));
-    properties->setString("height", style->getPropertyValue("height"));
-    result->setObject("properties", properties);
-    populateObjectWithStyleProperties(style, result.get());
-    return result.release();
-}
-
-void InspectorDOMAgent::populateObjectWithStyleProperties(CSSStyleDeclaration* style, InspectorObject* result)
-{
-    RefPtr<InspectorArray> properties = InspectorArray::create();
-    RefPtr<InspectorObject> shorthandValues = InspectorObject::create();
-
-    HashSet<String> foundShorthands;
-    for (unsigned i = 0; i < style->length(); ++i) {
-        RefPtr<InspectorObject> property = InspectorObject::create();
-        String name = style->item(i);
-        String value = style->getPropertyValue(name);
-        String priority = style->getPropertyPriority(name);
-        property->setString("name", name);
-        property->setString("value", value);
-        property->setString("priority", priority);
-        property->setString("text", name + ": " + value + (priority.length() ? " !" + priority : "") + ";");
-        property->setBoolean("implicit", style->isPropertyImplicit(name));
-        property->setBoolean("parsedOk", true);
-        property->setString("status", "style");
-        String shorthand = style->getPropertyShorthand(name);
-        property->setString("shorthandName", shorthand);
-        if (!shorthand.isEmpty() && !foundShorthands.contains(shorthand)) {
-            foundShorthands.add(shorthand);
-            shorthandValues->setString(shorthand, shorthandValue(style, shorthand));
-        }
-        properties->pushObject(property.release());
-    }
-    result->setArray("cssProperties", properties);
-    result->setString("cssText", style->cssText());
-    result->setObject("shorthandValues", shorthandValues);
-
-    DisabledStyleDeclaration* disabledStyle = cssStore()->disabledStyleForId(cssStore()->bindStyle(style), false);
-    if (!disabledStyle)
-        return;
-
-    for (DisabledStyleDeclaration::iterator it = disabledStyle->begin(); it != disabledStyle->end(); ++it) {
-        RefPtr<InspectorObject> property = InspectorObject::create();
-        String name = it->first;
-        String value = it->second.first;
-        String priority = it->second.second;
-        property->setString("name", name);
-        property->setString("value", value);
-        property->setString("priority", priority);
-        property->setString("text", name + ": " + value + (priority.length() ? " !" + priority : "") + ";");
-        property->setBoolean("implicit", false);
-        property->setBoolean("parsedOk", true);
-        property->setString("status", "disabled");
-        properties->pushObject(property.release());
-    }
-}
-
-PassRefPtr<InspectorObject> InspectorDOMAgent::buildObjectForStyleSheet(Document* ownerDocument, CSSStyleSheet* styleSheet)
-{
-    RefPtr<InspectorObject> result = InspectorObject::create();
-    long id = cssStore()->bindStyleSheet(styleSheet);
-    result->setNumber("styleSheetId", id);
-    result->setString("sourceURL", styleSheet->href());
-    result->setString("title", styleSheet->title());
-    result->setBoolean("disabled", styleSheet->disabled());
-    RefPtr<InspectorArray> cssRules = InspectorArray::create();
-    PassRefPtr<CSSRuleList> cssRuleList = CSSRuleList::create(styleSheet, true);
-    if (cssRuleList) {
-        for (unsigned i = 0; i < cssRuleList->length(); ++i) {
-            CSSRule* rule = cssRuleList->item(i);
-            if (rule->isStyleRule())
-                cssRules->pushObject(buildObjectForRule(ownerDocument, static_cast<CSSStyleRule*>(rule)));
-        }
-    }
-    result->setArray("rules", cssRules.release());
-    return result.release();
-}
-
-PassRefPtr<InspectorObject> InspectorDOMAgent::buildObjectForRule(Document* ownerDocument, CSSStyleRule* rule)
-{
-    CSSStyleSheet* parentStyleSheet = rule->parentStyleSheet();
-
-    RefPtr<InspectorObject> result = InspectorObject::create();
-    result->setString("selectorText", rule->selectorText());
-    result->setNumber("sourceLine", rule->sourceLine());
-
-    String origin;
-    bool canBind = true;
-    if (parentStyleSheet && !parentStyleSheet->ownerNode() && parentStyleSheet->href().isEmpty()) {
-        origin = "user-agent";
-        canBind = false;
-    } else if (parentStyleSheet && parentStyleSheet->ownerNode() && parentStyleSheet->ownerNode()->nodeName() == "#document") {
-        origin = "user";
-        canBind = false;
-    } else if (rule->parentStyleSheet() == cssStore()->inspectorStyleSheet(ownerDocument, false))
-        origin = "inspector";
-    result->setString("origin", origin);
-
-    if (origin.isEmpty())
-        result->setString("sourceURL", parentStyleSheet && !parentStyleSheet->href().isEmpty() ? parentStyleSheet->href() : (ownerDocument ? ownerDocument->url().string() : ""));
-
-    // Bind editable scripts only.
-    result->setObject("style", buildObjectForStyle(rule->style(), canBind));
-
-    if (canBind)
-        result->setNumber("ruleId", cssStore()->bindRule(rule));
-    return result.release();
-}
-
-Vector<String> InspectorDOMAgent::longhandProperties(CSSStyleDeclaration* style, const String& shorthandProperty)
-{
-    Vector<String> properties;
-    HashSet<String> foundProperties;
-
-    for (unsigned i = 0; i < style->length(); ++i) {
-        String individualProperty = style->item(i);
-        if (foundProperties.contains(individualProperty) || style->getPropertyShorthand(individualProperty) != shorthandProperty)
-            continue;
-        foundProperties.add(individualProperty);
-        properties.append(individualProperty);
-    }
-
-    return properties;
-}
-
-String InspectorDOMAgent::shorthandValue(CSSStyleDeclaration* style, const String& shorthandProperty)
-{
-    String value = style->getPropertyValue(shorthandProperty);
-    if (value.isEmpty()) {
-        // Some shorthands (like border) return a null value, so compute a shorthand value.
-        // FIXME: remove this when http://bugs.webkit.org/show_bug.cgi?id=15823 is fixed.
-        for (unsigned i = 0; i < style->length(); ++i) {
-            String individualProperty = style->item(i);
-            if (style->getPropertyShorthand(individualProperty) != shorthandProperty)
-                continue;
-            if (style->isPropertyImplicit(individualProperty))
-                continue;
-            String individualValue = style->getPropertyValue(individualProperty);
-            if (individualValue == "initial")
-                continue;
-            if (value.length())
-                value.append(" ");
-            value.append(individualValue);
-        }
-    }
-    return value;
-}
-
-String InspectorDOMAgent::shorthandPriority(CSSStyleDeclaration* style, const String& shorthandProperty)
-{
-    String priority = style->getPropertyPriority(shorthandProperty);
-    if (priority.isEmpty()) {
-        for (unsigned i = 0; i < style->length(); ++i) {
-            String individualProperty = style->item(i);
-            if (style->getPropertyShorthand(individualProperty) != shorthandProperty)
-                continue;
-            priority = style->getPropertyPriority(individualProperty);
-            break;
-        }
-    }
-    return priority;
-}
-
-bool InspectorDOMAgent::ruleAffectsNode(CSSStyleRule* rule, Node* node)
-{
-    if (!node)
-        return false;
-    ExceptionCode ec = 0;
-    RefPtr<NodeList> nodes = node->ownerDocument()->querySelectorAll(rule->selectorText(), ec);
-    if (ec)
-        return false;
-    for (unsigned i = 0; i < nodes->length(); ++i) {
-        if (nodes->item(i) == node)
-            return true;
-    }
-    return false;
-}
-
 Node* InspectorDOMAgent::nodeForPath(const String& path)
 {
     // The path is of form "1,HTML,2,BODY,1,DIV"
diff --git a/WebCore/inspector/InspectorDOMAgent.h b/WebCore/inspector/InspectorDOMAgent.h
index 84ca027..edd405b 100644
--- a/WebCore/inspector/InspectorDOMAgent.h
+++ b/WebCore/inspector/InspectorDOMAgent.h
@@ -33,7 +33,6 @@
 #include "Document.h"
 #include "EventListener.h"
 #include "EventTarget.h"
-#include "InspectorCSSStore.h"
 #include "InspectorValues.h"
 #include "NodeList.h"
 #include "Timer.h"
@@ -88,9 +87,9 @@ namespace WebCore {
             virtual void didRemoveDOMNode(Node*) = 0;
         };
 
-        static PassRefPtr<InspectorDOMAgent> create(InspectorCSSStore* cssStore, InspectorFrontend* frontend)
+        static PassRefPtr<InspectorDOMAgent> create(InspectorFrontend* frontend)
         {
-            return adoptRef(new InspectorDOMAgent(cssStore, frontend));
+            return adoptRef(new InspectorDOMAgent(frontend));
         }
 
         static const InspectorDOMAgent* cast(const EventListener* listener)
@@ -100,7 +99,7 @@ namespace WebCore {
                 : 0;
         }
 
-        InspectorDOMAgent(InspectorCSSStore* cssStore, InspectorFrontend* frontend);
+        InspectorDOMAgent(InspectorFrontend* frontend);
         ~InspectorDOMAgent();
 
         void reset();
@@ -124,20 +123,6 @@ namespace WebCore {
         bool shouldBreakOnNodeRemoval(Node* node, PassRefPtr<InspectorValue>* details);
         bool shouldBreakOnAttributeModification(Element* element, PassRefPtr<InspectorValue>* details);
 
-        // Methods called from the frontend for CSS styles inspection.
-        void getStyles(long nodeId, bool authorOnly, RefPtr<InspectorValue>* styles);
-        void getAllStyles(RefPtr<InspectorArray>* styles);
-        void getInlineStyle(long nodeId, RefPtr<InspectorValue>* styles);
-        void getComputedStyle(long nodeId, RefPtr<InspectorValue>* styles);
-        void getStyleSheet(long styleSheetId, RefPtr<InspectorObject>* styleSheetObject);
-        void getStyleSourceData(long styleId, RefPtr<InspectorObject>* dataObject);
-        void applyStyleText(long styleId, const String& styleText, const String& propertyName, bool* success, RefPtr<InspectorValue>* styleObject);
-        void setStyleText(long styleId, const String& cssText, bool* success);
-        void setStyleProperty(long styleId, const String& name, const String& value, bool* success);
-        void toggleStyleEnabled(long styleId, const String& propertyName, bool disabled, RefPtr<InspectorValue>* styleObject);
-        void setRuleSelector(long ruleId, const String& selector, long selectedNodeId, RefPtr<InspectorValue>* ruleObject, bool* selectorAffectsNode);
-        void addRule(const String& selector, long selectedNodeId, RefPtr<InspectorValue>* ruleObject, bool* selectorAffectsNode);
-
         // Methods called from the InspectorController.
         void setDocument(Document* document);
         void releaseDanglingNodes();
@@ -180,10 +165,6 @@ namespace WebCore {
         PassRefPtr<InspectorValue> descriptionForDOMEvent(Node* target, long breakpointType, bool insertion);
         String createBreakpointId(long nodeId, long type);
 
-        PassRefPtr<InspectorObject> buildObjectForAttributeStyles(Element* element);
-        PassRefPtr<InspectorArray> buildArrayForCSSRules(Document* ownerDocument, CSSRuleList*);
-        PassRefPtr<InspectorArray> buildArrayForPseudoElements(Element* element, bool authorOnly);
-
         PassRefPtr<InspectorObject> buildObjectForNode(Node* node, int depth, NodeToIdMap* nodesMap);
         PassRefPtr<InspectorArray> buildArrayForElementAttributes(Element* element);
         PassRefPtr<InspectorArray> buildArrayForContainerChildren(Node* container, int depth, NodeToIdMap* nodesMap);
@@ -199,25 +180,15 @@ namespace WebCore {
         bool isWhitespace(Node* node);
 
         Document* mainFrameDocument() const;
-        InspectorCSSStore* cssStore() { return m_cssStore; }
 
         void onMatchJobsTimer(Timer<InspectorDOMAgent>*);
         void reportNodesAsSearchResults(ListHashSet<Node*>& resultCollector);
 
-        PassRefPtr<InspectorObject> buildObjectForStyle(CSSStyleDeclaration*, bool bind);
-        void populateObjectWithStyleProperties(CSSStyleDeclaration*, InspectorObject* result);
-        PassRefPtr<InspectorObject> buildObjectForRule(Document* ownerDocument, CSSStyleRule*);
-        PassRefPtr<InspectorObject> buildObjectForStyleSheet(Document* ownerDocument, CSSStyleSheet*);
-        Vector<String> longhandProperties(CSSStyleDeclaration*, const String& shorthandProperty);
-        String shorthandValue(CSSStyleDeclaration*, const String& shorthandProperty);
-        String shorthandPriority(CSSStyleDeclaration*, const String& shorthandProperty);
-        bool ruleAffectsNode(CSSStyleRule*, Node*);
         Node* nodeForPath(const String& path);
         PassRefPtr<InspectorArray> toArray(const Vector<String>& data);
 
         void discardBindings();
 
-        InspectorCSSStore* m_cssStore;
         InspectorFrontend* m_frontend;
         DOMListener* m_domListener;
         NodeToIdMap m_documentNodeToIdMap;

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list