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

loislo at chromium.org loislo at chromium.org
Wed Dec 22 12:37:44 UTC 2010


The following commit has been merged in the debian/experimental branch:
commit dbd6bd336843e7a0ebbf6b16a6682700ebd6f782
Author: loislo at chromium.org <loislo at chromium.org@268f45cc-cd09-0410-ab3c-d52691b4dbfc>
Date:   Thu Aug 26 08:29:59 2010 +0000

    2010-08-25  Ilya Tikhonovsky  <loislo at chromium.org>
    
            Reviewed by Pavel Feldman.
    
            WebInspector: as far as we have 'seq' property in the each inspector message
            it would be better to remove explicit callId argument from Inspector.idl functions
            declarations.
            https://bugs.webkit.org/show_bug.cgi?id=44617
    
            * WebCore.xcodeproj/project.pbxproj:
            * inspector/CodeGeneratorInspector.pm:
            * inspector/Inspector.idl:
            * inspector/front-end/AuditRules.js:
            * inspector/front-end/BreakpointManager.js:
            * inspector/front-end/CSSStyleModel.js:
            * inspector/front-end/DOMAgent.js:
            * inspector/front-end/DOMStorage.js:
            * inspector/front-end/Database.js:
            * inspector/front-end/ElementsPanel.js:
            * inspector/front-end/ElementsTreeOutline.js:
            * inspector/front-end/InjectedScriptAccess.js:
            * inspector/front-end/MetricsSidebarPane.js:
            * inspector/front-end/ProfileView.js:
            * inspector/front-end/ProfilesPanel.js:
            * inspector/front-end/ResourcesPanel.js:
            * inspector/front-end/ScriptView.js:
            * inspector/front-end/ScriptsPanel.js:
            * inspector/front-end/inspector.js:
    
    2010-08-25  Ilya Tikhonovsky  <loislo at chromium.org>
    
            Reviewed by Pavel Feldman.
    
            WebInspector: as far as we have 'seq' property in the each inspector message
            it would be better to remove explicit callId argument from Inspector.idl functions
            declarations.
            https://bugs.webkit.org/show_bug.cgi?id=44617
    
            * inspector/elements-panel-search.html:
            * inspector/styles-iframe.html:
            * inspector/styles-source-lines.html:
            * inspector/styles-source-offsets.html:
            * http/tests/inspector/inspect-iframe-from-different-domain.html
    
    2010-08-25  Ilya Tikhonovsky  <loislo at chromium.org>
    
            Reviewed by Pavel Feldman.
    
            WebInspector: as far as we have 'seq' property in the each inspector message
            it would be better to remove explicit callId argument from Inspector.idl functions
            declarations.
            https://bugs.webkit.org/show_bug.cgi?id=44617
    
            * src/js/ProfilerAgent.js:
            (devtools.ProfilerAgent.prototype._getNextLogLines.else.delayedRequest):
            (devtools.ProfilerAgent.prototype._getNextLogLines):
    
    
    
    
    git-svn-id: http://svn.webkit.org/repository/webkit/trunk@66087 268f45cc-cd09-0410-ab3c-d52691b4dbfc

diff --git a/LayoutTests/ChangeLog b/LayoutTests/ChangeLog
index 14c4992..cf66498 100644
--- a/LayoutTests/ChangeLog
+++ b/LayoutTests/ChangeLog
@@ -1,3 +1,19 @@
+2010-08-25  Ilya Tikhonovsky  <loislo at chromium.org>
+
+        Reviewed by Pavel Feldman.
+
+        WebInspector: as far as we have 'seq' property in the each inspector message
+        it would be better to remove explicit callId argument from Inspector.idl functions
+        declarations.
+        https://bugs.webkit.org/show_bug.cgi?id=44617
+
+        * inspector/elements-panel-search.html:
+        * inspector/styles-iframe.html:
+        * inspector/styles-source-lines.html:
+        * inspector/styles-source-offsets.html:
+        * http/tests/inspector/inspect-iframe-from-different-domain.html
+
+
 2010-08-26  Philippe Normand  <pnormand at igalia.com>
 
         Unreviewed, skipping a flakey test.
diff --git a/LayoutTests/http/tests/inspector/inspect-iframe-from-different-domain.html b/LayoutTests/http/tests/inspector/inspect-iframe-from-different-domain.html
index 3f8e607..128b48f 100644
--- a/LayoutTests/http/tests/inspector/inspect-iframe-from-different-domain.html
+++ b/LayoutTests/http/tests/inspector/inspect-iframe-from-different-domain.html
@@ -90,7 +90,7 @@ function frontend_dumpIFrameBackground(testController)
                 testController.notifyDone("Background property not found");
             }
 
-            InspectorBackend.getStyles(WebInspector.Callback.wrap(callback), domNode.id, true);
+            InspectorBackend.getStyles(domNode.id, true, callback);
         });
     });
 }
diff --git a/LayoutTests/inspector/elements-panel-search.html b/LayoutTests/inspector/elements-panel-search.html
index 1e8ffbe..b69c745 100755
--- a/LayoutTests/inspector/elements-panel-search.html
+++ b/LayoutTests/inspector/elements-panel-search.html
@@ -35,10 +35,8 @@ function frontend_performSearch(testController)
             var node = WebInspector.domAgent.nodeForId(nodeIds[i]);
             if (node.nodeType === Node.TEXT_NODE)
                 searchResults.push(node.nodeValue);
-            else {
-                var callId = WebInspector.Callback.wrap(addSearchResult);
-                InspectorBackend.getOuterHTML(callId, node.id);
-            }
+            else
+                InspectorBackend.getOuterHTML(node.id, addSearchResult);
         }
     }
     // Plain text.
diff --git a/LayoutTests/inspector/styles-iframe.html b/LayoutTests/inspector/styles-iframe.html
index 8c9fbd0..fbacf39 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(WebInspector.Callback.wrap(mainFrameCallback), body.id, false);
+    InspectorBackend.getStyles(body.id, false, mainFrameCallback);
 
     // 2. Find iframe node
     var innerMapping = WebInspector.domAgent._idToDOMNode;
@@ -67,7 +67,7 @@ function frontend_dumpStylesContinuation(testController)
         testController.notifyDone([mainStyles, styles]);
     }
 
-    InspectorBackend.getStyles(WebInspector.Callback.wrap(iframeCallback), iframeBody.id, false);
+    InspectorBackend.getStyles(iframeBody.id, false, iframeCallback);
 }
 
 </script>
diff --git a/LayoutTests/inspector/styles-source-lines.html b/LayoutTests/inspector/styles-source-lines.html
index 517150a..ee01f2c 100755
--- a/LayoutTests/inspector/styles-source-lines.html
+++ b/LayoutTests/inspector/styles-source-lines.html
@@ -85,7 +85,7 @@ function frontend_getRawStyles(testController)
     {
         testController.notifyDone(styles);
     }
-    InspectorBackend.getStyles(WebInspector.Callback.wrap(callback), WebInspector.domAgent.document.body.id, true);
+    InspectorBackend.getStyles(WebInspector.domAgent.document.body.id, true, callback);
 }
 
 </script>
diff --git a/LayoutTests/inspector/styles-source-offsets.html b/LayoutTests/inspector/styles-source-offsets.html
index 2d59972..0533611 100644
--- a/LayoutTests/inspector/styles-source-offsets.html
+++ b/LayoutTests/inspector/styles-source-offsets.html
@@ -41,9 +41,9 @@ function frontend_runTest(testController)
                 testController.notifyDone(testController.results);
                 return;
             }
-            InspectorBackend.getRuleRanges(WebInspector.Callback.wrap(frontend_ruleRangesReceived.bind(null, testController, parentStyleSheetId, matchedCSSRules)), parentStyleSheetId);
+            InspectorBackend.getRuleRanges(parentStyleSheetId, frontend_ruleRangesReceived.bind(null, testController, parentStyleSheetId, matchedCSSRules));
         }
-        InspectorBackend.getStyles(WebInspector.Callback.wrap(stylesCallback.bind(null, testController)), WebInspector.domAgent.document.body.id, true);
+        InspectorBackend.getStyles(WebInspector.domAgent.document.body.id, true, stylesCallback.bind(null, testController));
     });
 }
 
@@ -53,7 +53,7 @@ function frontend_ruleRangesReceived(testController, styleSheetId, matchedCSSRul
         var rule = matchedCSSRules[i];
         testController.results.push(rule.selectorText + ": [" + ruleRanges[rule.style.id].bodyRange.start + "-" + ruleRanges[rule.style.id].bodyRange.end + "]");
     }
-    InspectorBackend.getStyleSheet(WebInspector.Callback.wrap(frontend_handleStyleSheet.bind(null, testController)), styleSheetId);
+    InspectorBackend.getStyleSheet(styleSheetId, frontend_handleStyleSheet.bind(null, testController));
 }
 
 function frontend_handleStyleSheet(testController, styleSheet)
diff --git a/WebCore/ChangeLog b/WebCore/ChangeLog
index e08244c..da93a9b 100644
--- a/WebCore/ChangeLog
+++ b/WebCore/ChangeLog
@@ -1,3 +1,66 @@
+2010-08-25  Ilya Tikhonovsky  <loislo at chromium.org>
+
+        Reviewed by Pavel Feldman.
+
+        WebInspector: as far as we have 'seq' property in the each inspector message
+        it would be better to remove explicit callId argument from Inspector.idl functions
+        declarations.
+        https://bugs.webkit.org/show_bug.cgi?id=44617
+
+        * WebCore.xcodeproj/project.pbxproj:
+        * inspector/CodeGeneratorInspector.pm:
+        * inspector/Inspector.idl:
+        * inspector/front-end/AuditRules.js:
+        (WebInspector.AuditRules.UnusedCssRule.prototype.doRun):
+        (WebInspector.AuditRules.ImageDimensionsRule.prototype.doRun.receivedImages):
+        * inspector/front-end/BreakpointManager.js:
+        (WebInspector.BreakpointManager.prototype._setBreakpointOnBackend):
+        * inspector/front-end/CSSStyleModel.js:
+        (WebInspector.CSSStyleModel.prototype.getStylesAsync):
+        (WebInspector.CSSStyleModel.prototype.getComputedStyleAsync):
+        (WebInspector.CSSStyleModel.prototype.setRuleSelector):
+        (WebInspector.CSSStyleModel.prototype.addRule):
+        (WebInspector.CSSStyleModel.prototype.toggleStyleEnabled):
+        (WebInspector.CSSStyleModel.prototype.setCSSText):
+        (WebInspector.CSSStyleModel.prototype.applyStyleText):
+        * inspector/front-end/DOMAgent.js:
+        (WebInspector.DOMAgent.prototype.getChildNodesAsync):
+        (WebInspector.DOMAgent.prototype.setAttributeAsync):
+        (WebInspector.DOMAgent.prototype.removeAttributeAsync):
+        (WebInspector.DOMAgent.prototype.setTextNodeValueAsync):
+        (WebInspector.ApplicationCache.getApplicationCachesAsync):
+        (WebInspector.Cookies.getCookiesAsync):
+        (WebInspector.EventListeners.getEventListenersForNodeAsync):
+        * inspector/front-end/DOMStorage.js:
+        (WebInspector.DOMStorage.prototype.getEntries):
+        (WebInspector.DOMStorage.prototype.setItem):
+        (WebInspector.DOMStorage.prototype.removeItem):
+        * inspector/front-end/Database.js:
+        (WebInspector.Database.prototype.getTableNames):
+        (WebInspector.Database.prototype.executeSql):
+        * inspector/front-end/ElementsPanel.js:
+        (WebInspector.ElementsPanel.prototype.setDocument):
+        * inspector/front-end/ElementsTreeOutline.js:
+        (WebInspector.ElementsTreeElement.prototype._tagNameEditingCommitted):
+        ():
+        * inspector/front-end/InjectedScriptAccess.js:
+        (InjectedScriptAccess._installHandler.InjectedScriptAccess.prototype.methodName):
+        (InjectedScriptAccess._installHandler):
+        * inspector/front-end/MetricsSidebarPane.js:
+        (WebInspector.MetricsSidebarPane.prototype.update):
+        (WebInspector.MetricsSidebarPane.prototype.editingCommitted):
+        * inspector/front-end/ProfileView.js:
+        (WebInspector.CPUProfileView):
+        * inspector/front-end/ProfilesPanel.js:
+        * inspector/front-end/ResourcesPanel.js:
+        (WebInspector.getResourceContent):
+        * inspector/front-end/ScriptView.js:
+        (WebInspector.ScriptView.prototype.setupSourceFrameIfNeeded):
+        * inspector/front-end/ScriptsPanel.js:
+        (WebInspector.ScriptsPanel.prototype.editScriptSource):
+        * inspector/front-end/inspector.js:
+        (WebInspector.doLoadedDone):
+
 2010-08-26  Kwang Yul Seo  <skyul at company100.net>
 
         Reviewed by Kent Tamura.
diff --git a/WebCore/inspector/CodeGeneratorInspector.pm b/WebCore/inspector/CodeGeneratorInspector.pm
index be0948b..7223e9e 100644
--- a/WebCore/inspector/CodeGeneratorInspector.pm
+++ b/WebCore/inspector/CodeGeneratorInspector.pm
@@ -351,12 +351,9 @@ sub generateBackendFunction
     push(@function, "");
 
     push(@function, "    // use InspectorFrontend as a marker of WebInspector availability");
-    push(@function, "    if (callId && m_inspectorController->hasFrontend()) {");
+    push(@function, "    if ((callId || protocolErrors->length()) && m_inspectorController->hasFrontend()) {");
     push(@function, "        RefPtr<InspectorObject> responseMessage = InspectorObject::create();");
     push(@function, "        responseMessage->setNumber(\"seq\", callId);");
-    push(@function, "        responseMessage->setString(\"type\", \"response\");");
-    push(@function, "        responseMessage->setString(\"domain\", \"$domain\");");
-    push(@function, "        responseMessage->setString(\"command\", \"$functionName\");");
     push(@function, "        responseMessage->setBool(\"success\", !protocolErrors->length());");
     push(@function, "");
     push(@function, "        if (protocolErrors->length())");
@@ -432,30 +429,30 @@ $mapEntries
         return;
     }
 
-    RefPtr<InspectorValue> callIdValue = messageObject->get("seq");
-    if (!callIdValue) {
+    RefPtr<InspectorValue> commandValue = messageObject->get("command");
+    if (!commandValue) {
         ASSERT_NOT_REACHED();
-        reportProtocolError(callId, "dispatch", "Error: Invalid message format. 'seq' property was not found in the request.");
+        reportProtocolError(callId, "dispatch", "Error: Invalid message format. 'command' property wasn't found.");
         return;
     }
 
-    if (!callIdValue->asNumber(&callId)) {
+    String command;
+    if (!commandValue->asString(&command)) {
         ASSERT_NOT_REACHED();
-        reportProtocolError(callId, "dispatch", "Error: Invalid message format. the type of 'seq' property should be number.");
+        reportProtocolError(callId, "dispatch", "Error: Invalid message format. The type of 'command' property should be string.");
         return;
     }
 
-    RefPtr<InspectorValue> commandValue = messageObject->get("command");
-    if (!commandValue) {
+    RefPtr<InspectorValue> callIdValue = messageObject->get("seq");
+    if (!callIdValue) {
         ASSERT_NOT_REACHED();
-        reportProtocolError(callId, "dispatch", "Error: Invalid message format. 'command' property wasn't found.");
+        reportProtocolError(callId, command.utf8().data(), "Error: Invalid message format. 'seq' property was not found in the request.");
         return;
     }
 
-    String command;
-    if (!commandValue->asString(&command)) {
+    if (!callIdValue->asNumber(&callId)) {
         ASSERT_NOT_REACHED();
-        reportProtocolError(callId, "dispatch", "Error: Invalid message format. The type of 'command' property should be string.");
+        reportProtocolError(callId, command.utf8().data(), "Error: Invalid message format. the type of 'seq' property should be number.");
         return;
     }
 
@@ -508,7 +505,6 @@ sub generateBackendStubJS
         my $argumentNames = join(",", map("\"" . $_->name . "\": null", grep($_->direction eq "in", @{$function->parameters})));
         push(@JSStubs, "    this._registerDelegate('{" .
             "\"seq\": 0, " .
-            "\"type\": \"request\", " .
             "\"domain\": \"$domain\", " .
             "\"command\": \"$name\", " .
             "\"arguments\": {$argumentNames}" .
@@ -535,12 +531,10 @@ WebInspector.InspectorBackendStub.prototype = {
     {
         var args = Array.prototype.slice.call(arguments);
         var request = JSON.parse(args.shift());
-        for (var key in request.arguments) {
-            if (key === "callId")
-                request.seq = args.shift();
-            else
-                request.arguments[key] = args.shift();
-        }
+
+        for (var key in request.arguments)
+            request.arguments[key] = args.shift();
+
         if (args.length === 1 && typeof args[0] === "function")
             request.seq = WebInspector.Callback.wrap(args[0]);
 
diff --git a/WebCore/inspector/Inspector.idl b/WebCore/inspector/Inspector.idl
index a56ef14..7f39f8d 100644
--- a/WebCore/inspector/Inspector.idl
+++ b/WebCore/inspector/Inspector.idl
@@ -102,7 +102,7 @@ module core {
         // This method is going to be broken down into smaller parts.
         [handler=Controller] void populateScriptObjects();
 
-        [handler=Controller] void getSettings(in long callId, out Object settings);
+        [handler=Controller] void getSettings(out Object settings);
         [handler=Controller] void storeLastActivePanel(in String panelName);
 
         [handler=Controller] void saveApplicationSettings(in String settings);
@@ -116,7 +116,7 @@ module core {
 
         [handler=Controller] void enableResourceTracking(in boolean always);
         [handler=Controller] void disableResourceTracking(in boolean always);
-        [handler=Controller] void getResourceContent(in long callId, in unsigned long identifier, out String content);
+        [handler=Controller] void getResourceContent(in unsigned long identifier, out String content);
         [handler=Controller] void reloadPage();
 
         [handler=Controller] void startTimelineProfiler();
@@ -126,7 +126,7 @@ module core {
         [handler=Backend] void enableDebugger(in boolean always);
         [handler=Controller] void disableDebugger(in boolean always);
 
-        [handler=Debug] void setBreakpoint(in long callId, in String sourceID, in unsigned int lineNumber, in boolean enabled, in String condition, out boolean success, out unsigned int actualLineNumber);
+        [handler=Debug] void setBreakpoint(in String sourceID, in unsigned int lineNumber, in boolean enabled, in String condition, out boolean success, out unsigned int actualLineNumber);
         [handler=Debug] void removeBreakpoint(in String sourceID, in unsigned long lineNumber);
         [handler=Debug] void activateBreakpoints();
         [handler=Debug] void deactivateBreakpoints();
@@ -140,8 +140,8 @@ module core {
 
         [handler=Debug] void setPauseOnExceptionsState(in long pauseOnExceptionsState);
 
-        [handler=Debug] void editScriptSource(in long callId, in String sourceID, in String newContent, out boolean success, out String result, out Value newCallFrames);
-        [handler=Debug] void getScriptSource(in long callId, in String sourceID, out String scriptSource);
+        [handler=Debug] void editScriptSource(in String sourceID, in String newContent, out boolean success, out String result, out Value newCallFrames);
+        [handler=Debug] void getScriptSource(in String sourceID, out String scriptSource);
 
         [handler=Controller] void enableProfiler(in boolean always);
         [handler=Controller] void disableProfiler(in boolean always);
@@ -149,34 +149,34 @@ module core {
         [handler=Profiler] void startProfiling();
         [handler=Profiler] void stopProfiling();
 
-        [handler=Profiler] void getProfileHeaders(in long callId, out Array headers);
-        [handler=Profiler] void getProfile(in long callId, in unsigned long uid, out Object profile);
+        [handler=Profiler] void getProfileHeaders(out Array headers);
+        [handler=Profiler] void getProfile(in unsigned long uid, out Object profile);
 
         [handler=Profiler] void removeProfile(in unsigned long uid);
         [handler=Profiler] void clearProfiles();
 
         [handler=Backend] void takeHeapSnapshot();
-        [handler=Backend] void getProfilerLogLines(in long callId, in long inPosition, out long outPosition, out String log);
+        [handler=Backend] void getProfilerLogLines(in long inPosition, out long outPosition, out String log);
 #endif
         [handler=Backend] void setInjectedScriptSource(in String scriptSource);
-        [handler=Backend] void dispatchOnInjectedScript(in long callId, in long injectedScriptId, in String methodName, in String arguments, out Value result, out boolean isException);
+        [handler=Backend] void dispatchOnInjectedScript(in long injectedScriptId, in String methodName, in String arguments, out Value result, out boolean isException);
         [handler=Controller] void addScriptToEvaluateOnLoad(in String scriptSource);
         [handler=Controller] void removeAllScriptsToEvaluateOnLoad();
 
-        [handler=DOM] void getChildNodes(in long callId, in long nodeId);
-        [handler=DOM] void setAttribute(in long callId, in long elementId, in String name, in String value, out boolean success);
-        [handler=DOM] void removeAttribute(in long callId, in long elementId, in String name, out boolean success);
-        [handler=DOM] void setTextNodeValue(in long callId, in long nodeId, in String value, out boolean success);
-        [handler=DOM] void getEventListenersForNode(in long callId, in long nodeId, out long outNodeId, out Array listenersArray);
+        [handler=DOM] void getChildNodes(in long nodeId);
+        [handler=DOM] void setAttribute(in long elementId, in String name, in String value, out boolean success);
+        [handler=DOM] void removeAttribute(in long elementId, in String name, out boolean success);
+        [handler=DOM] void setTextNodeValue(in long nodeId, in String value, out boolean success);
+        [handler=DOM] void getEventListenersForNode(in long nodeId, out long outNodeId, out Array listenersArray);
         [handler=DOM] void copyNode(in long nodeId);
-        [handler=DOM] void removeNode(in long callId, in long nodeId, out long outNodeId);
-        [handler=DOM] void changeTagName(in long callId, in long nodeId, in String newTagName, out long outNodeId);
-        [handler=DOM] void getOuterHTML(in long callId, in long nodeId, out String outerHTML);
-        [handler=DOM] void setOuterHTML(in long callId, in long nodeId, in String outerHTML, out long outNodeId);
+        [handler=DOM] void removeNode(in long nodeId, out long outNodeId);
+        [handler=DOM] void changeTagName(in long nodeId, in String newTagName, out long outNodeId);
+        [handler=DOM] void getOuterHTML(in long nodeId, out String outerHTML);
+        [handler=DOM] void setOuterHTML(in long nodeId, in String outerHTML, out long outNodeId);
         [handler=DOM] void addInspectedNode(in long nodeId);
         [handler=DOM] void performSearch(in String query, in boolean runSynchronously);
         [handler=DOM] void searchCanceled();
-        [handler=DOM] void pushNodeByPathToFrontend(in long callId, in String path, out long nodeId);
+        [handler=DOM] void pushNodeByPathToFrontend(in String path, out long nodeId);
         [handler=DOM] void setDOMBreakpoint(in long nodeId, in long type);
         [handler=DOM] void removeDOMBreakpoint(in long nodeId, in long type);
 
@@ -185,41 +185,41 @@ module core {
         [handler=Controller] void hideDOMNodeHighlight();
         [handler=Controller] void openInInspectedWindow(in String url);
 
-        [handler=DOM] void getStyles(in long callId, in long nodeId, in boolean authOnly, out Value styles);
-        [handler=DOM] void getAllStyles(in long callId, out Array styles);
-        [handler=DOM] void getInlineStyle(in long callId, in long nodeId, out Value style);
-        [handler=DOM] void getComputedStyle(in long callId, in long nodeId, out Value style);
-        [handler=DOM] void getStyleSheet(in long callId, in long styleSheetId, out Object styleSheet);
-        [handler=DOM] void getRuleRanges(in long callId, in long styleSheetId, out Value ranges);
-        [handler=DOM] void applyStyleText(in long callId, in long styleId, in String styleText, in String propertyName, out boolean success, out Value style, out Array changedProperties);
-        [handler=DOM] void setStyleText(in long callId, in long styleId, in String styleText, out boolean success);
-        [handler=DOM] void setStyleProperty(in long callId, in long styleId, in String name, in String value, out boolean success);
-        [handler=DOM] void toggleStyleEnabled(in long callId, in long styleId, in String propertyName, in boolean disabled, out Value style);
-        [handler=DOM] void setRuleSelector(in long callId, in long ruleId, in String selector, in long selectedNodeId, out Value rule, out boolean selectorAffectsNode);
-        [handler=DOM] void addRule(in long callId, in String selector, in long selectedNodeId, out Value rule, out boolean selectorAffectsNode);
-        [handler=DOM] void getSupportedCSSProperties(in long callId, out Array cssProperties);
-
-        [handler=Controller] void getCookies(in long callId, out Array cookies, out String cookiesString);
+        [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 getRuleRanges(in long styleSheetId, out Value ranges);
+        [handler=DOM] void applyStyleText(in long styleId, in String styleText, in String propertyName, out boolean success, out Value style, out Array changedProperties);
+        [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=DOM] void getSupportedCSSProperties(out Array cssProperties);
+
+        [handler=Controller] void getCookies(out Array cookies, out String cookiesString);
         [handler=Controller] void deleteCookie(in String cookieName, in String domain);
 
 #if defined(ENABLE_OFFLINE_WEB_APPLICATIONS) && ENABLE_OFFLINE_WEB_APPLICATIONS
-        [handler=ApplicationCache] void getApplicationCaches(in long callId, out Value applicationCaches);
+        [handler=ApplicationCache] void getApplicationCaches(out Value applicationCaches);
 #endif
 
         [handler=Backend] void releaseWrapperObjectGroup(in long injectedScriptId, in String objectGroup);
         [handler=Controller] void didEvaluateForTestInFrontend(in long testCallId, in String jsonResult);
 
 #if defined(ENABLE_DATABASE) && ENABLE_DATABASE
-        [handler=Backend] void getDatabaseTableNames(in long callId, in long databaseId, out Array tableNames);
-        [handler=Backend] void executeSQL(in long callId, in long databaseId, in String query, out boolean success, out long transactionId);
+        [handler=Backend] void getDatabaseTableNames(in long databaseId, out Array tableNames);
+        [handler=Backend] void executeSQL(in long databaseId, in String query, out boolean success, out long transactionId);
         [notify] void sqlTransactionSucceeded(out long transactionId, out Value columnNames, out Value values);
         [notify] void sqlTransactionFailed(out long transactionId, out Value sqlError);
 #endif
 
 #if defined(ENABLE_DOM_STORAGE) && ENABLE_DOM_STORAGE
-        [handler=Controller] void getDOMStorageEntries(in long callId, in long storageId, out Array entries);
-        [handler=Controller] void setDOMStorageItem(in long callId, in long storageId, in String key, in String value, out boolean success);
-        [handler=Controller] void removeDOMStorageItem(in long callId, in long storageId, in String key, out boolean success);
+        [handler=Controller] void getDOMStorageEntries(in long storageId, out Array entries);
+        [handler=Controller] void setDOMStorageItem(in long storageId, in String key, in String value, out boolean success);
+        [handler=Controller] void removeDOMStorageItem(in long storageId, in String key, out boolean success);
 #endif
     };
 }
diff --git a/WebCore/inspector/front-end/AuditRules.js b/WebCore/inspector/front-end/AuditRules.js
index e28a364..a72de56 100644
--- a/WebCore/inspector/front-end/AuditRules.js
+++ b/WebCore/inspector/front-end/AuditRules.js
@@ -371,7 +371,7 @@ WebInspector.AuditRules.UnusedCssRule.prototype = {
             return routineResult;
         }
 
-        InspectorBackend.getAllStyles(WebInspector.Callback.wrap(evalCallback));
+        InspectorBackend.getAllStyles(evalCallback);
     }
 }
 
@@ -693,7 +693,7 @@ WebInspector.AuditRules.ImageDimensionsRule.prototype = {
                 return callback(null);
             var context = {imagesLeft: imageIds.length, urlToNoDimensionCount: {}};
             for (var i = imageIds.length - 1; i >= 0; --i)
-                InspectorBackend.getStyles(WebInspector.Callback.wrap(imageStylesReady.bind(this, imageIds[i], context)), imageIds[i], true);
+                InspectorBackend.getStyles(imageIds[i], true, imageStylesReady.bind(this, imageIds[i], context));
         }
 
         function pushImageNodes()
diff --git a/WebCore/inspector/front-end/BreakpointManager.js b/WebCore/inspector/front-end/BreakpointManager.js
index 824bc31..8518618 100644
--- a/WebCore/inspector/front-end/BreakpointManager.js
+++ b/WebCore/inspector/front-end/BreakpointManager.js
@@ -123,8 +123,7 @@ WebInspector.BreakpointManager.prototype = {
                     this._setBreakpoint(breakpoint.sourceID, breakpoint.url, line, breakpoint.enabled, breakpoint.condition);
             }
         }
-        var callbackId = WebInspector.Callback.wrap(didSetBreakpoint.bind(this));
-        InspectorBackend.setBreakpoint(callbackId, breakpoint.sourceID, breakpoint.line, breakpoint.enabled, breakpoint.condition);
+        InspectorBackend.setBreakpoint(breakpoint.sourceID, breakpoint.line, breakpoint.enabled, breakpoint.condition, didSetBreakpoint.bind(this));
     }
 }
 
diff --git a/WebCore/inspector/front-end/CSSStyleModel.js b/WebCore/inspector/front-end/CSSStyleModel.js
index 66a20ce..bda4064 100644
--- a/WebCore/inspector/front-end/CSSStyleModel.js
+++ b/WebCore/inspector/front-end/CSSStyleModel.js
@@ -35,12 +35,12 @@ WebInspector.CSSStyleModel = function()
 WebInspector.CSSStyleModel.prototype = {
     getStylesAsync: function(nodeId, authOnly, userCallback)
     {
-        InspectorBackend.getStyles(WebInspector.Callback.wrap(userCallback), nodeId, authOnly);
+        InspectorBackend.getStyles(nodeId, authOnly, userCallback);
     },
 
     getComputedStyleAsync: function(nodeId, userCallback)
     {
-        InspectorBackend.getComputedStyle(WebInspector.Callback.wrap(userCallback), nodeId);
+        InspectorBackend.getComputedStyle(nodeId, userCallback);
     },
 
     setRuleSelector: function(ruleId, newContent, nodeId, successCallback, failureCallback)
@@ -53,7 +53,7 @@ WebInspector.CSSStyleModel.prototype = {
                 successCallback(WebInspector.CSSStyleDeclaration.parseRule(newRulePayload), doesAffectSelectedNode);
         }
 
-        InspectorBackend.setRuleSelector(WebInspector.Callback.wrap(callback), ruleId, newContent, nodeId);
+        InspectorBackend.setRuleSelector(ruleId, newContent, nodeId, callback);
     },
 
     addRule: function(nodeId, newContent, successCallback, failureCallback)
@@ -70,7 +70,7 @@ WebInspector.CSSStyleModel.prototype = {
             }
         }
 
-        InspectorBackend.addRule(WebInspector.Callback.wrap(callback), newContent, nodeId);
+        InspectorBackend.addRule(newContent, nodeId, callback);
     },
 
     toggleStyleEnabled: function(styleId, propertyName, disabled, userCallback)
@@ -86,12 +86,12 @@ WebInspector.CSSStyleModel.prototype = {
             userCallback(newStyle);
         }
 
-        InspectorBackend.toggleStyleEnabled(WebInspector.Callback.wrap(callback), styleId, propertyName, disabled);
+        InspectorBackend.toggleStyleEnabled(styleId, propertyName, disabled, callback);
     },
 
     setCSSText: function(styleId, cssText)
     {
-        InspectorBackend.setStyleText(WebInspector.Callback.wrap(null), styleId, cssText);
+        InspectorBackend.setStyleText(styleId, cssText);
     },
 
     applyStyleText: function(styleId, styleText, propertyName, successCallback, failureCallback)
@@ -106,6 +106,6 @@ WebInspector.CSSStyleModel.prototype = {
             }
         }
 
-        InspectorBackend.applyStyleText(WebInspector.Callback.wrap(callback), styleId, styleText, propertyName);
+        InspectorBackend.applyStyleText(styleId, styleText, propertyName, callback);
     }
 }
diff --git a/WebCore/inspector/front-end/DOMAgent.js b/WebCore/inspector/front-end/DOMAgent.js
index 0d79d51..bd52235 100644
--- a/WebCore/inspector/front-end/DOMAgent.js
+++ b/WebCore/inspector/front-end/DOMAgent.js
@@ -306,26 +306,25 @@ WebInspector.DOMAgent.prototype = {
         function mycallback() {
             callback(parent.children);
         }
-        var callId = WebInspector.Callback.wrap(mycallback);
-        InspectorBackend.getChildNodes(callId, parent.id);
+        InspectorBackend.getChildNodes(parent.id, mycallback);
     },
 
     setAttributeAsync: function(node, name, value, callback)
     {
         var mycallback = this._didApplyDomChange.bind(this, node, callback);
-        InspectorBackend.setAttribute(WebInspector.Callback.wrap(mycallback), node.id, name, value);
+        InspectorBackend.setAttribute(node.id, name, value, mycallback);
     },
 
     removeAttributeAsync: function(node, name, callback)
     {
         var mycallback = this._didApplyDomChange.bind(this, node, callback);
-        InspectorBackend.removeAttribute(WebInspector.Callback.wrap(mycallback), node.id, name);
+        InspectorBackend.removeAttribute(node.id, name, mycallback);
     },
 
     setTextNodeValueAsync: function(node, text, callback)
     {
         var mycallback = this._didApplyDomChange.bind(this, node, callback);
-        InspectorBackend.setTextNodeValue(WebInspector.Callback.wrap(mycallback), node.id, text);
+        InspectorBackend.setTextNodeValue(node.id, text, mycallback);
     },
 
     _didApplyDomChange: function(node, callback, success)
@@ -429,8 +428,7 @@ WebInspector.ApplicationCache.getApplicationCachesAsync = function(callback)
             callback(applicationCaches);
     }
 
-    var callId = WebInspector.Callback.wrap(mycallback);
-    InspectorBackend.getApplicationCaches(callId);
+    InspectorBackend.getApplicationCaches(mycallback);
 }
 
 WebInspector.Cookies = {}
@@ -445,8 +443,7 @@ WebInspector.Cookies.getCookiesAsync = function(callback)
             callback(cookies, true);
     }
 
-    var callId = WebInspector.Callback.wrap(mycallback);
-    InspectorBackend.getCookies(callId);
+    InspectorBackend.getCookies(mycallback);
 }
 
 WebInspector.Cookies.buildCookiesFromString = function(rawCookieString)
@@ -496,9 +493,7 @@ WebInspector.EventListeners.getEventListenersForNodeAsync = function(node, callb
 {
     if (!node)
         return;
-
-    var callId = WebInspector.Callback.wrap(callback);
-    InspectorBackend.getEventListenersForNode(callId, node.id);
+    InspectorBackend.getEventListenersForNode(node.id, callback);
 }
 
 WebInspector.CSSStyleDeclaration = function(payload)
diff --git a/WebCore/inspector/front-end/DOMStorage.js b/WebCore/inspector/front-end/DOMStorage.js
index 5c28e29..37be8f6 100644
--- a/WebCore/inspector/front-end/DOMStorage.js
+++ b/WebCore/inspector/front-end/DOMStorage.js
@@ -56,20 +56,17 @@ WebInspector.DOMStorage.prototype = {
 
     getEntries: function(callback)
     {
-        var callId = WebInspector.Callback.wrap(callback);
-        InspectorBackend.getDOMStorageEntries(callId, this._id);
+        InspectorBackend.getDOMStorageEntries(this._id, callback);
     },
     
     setItem: function(key, value, callback)
     {
-        var callId = WebInspector.Callback.wrap(callback);
-        InspectorBackend.setDOMStorageItem(callId, this._id, key, value);
+        InspectorBackend.setDOMStorageItem(this._id, key, value, callback);
     },
     
     removeItem: function(key, callback)
     {
-        var callId = WebInspector.Callback.wrap(callback);
-        InspectorBackend.removeDOMStorageItem(callId, this._id, key);
+        InspectorBackend.removeDOMStorageItem(this._id, key, callback);
     }
 }
 
diff --git a/WebCore/inspector/front-end/Database.js b/WebCore/inspector/front-end/Database.js
index 45b7a0e..ca3e968 100644
--- a/WebCore/inspector/front-end/Database.js
+++ b/WebCore/inspector/front-end/Database.js
@@ -84,8 +84,7 @@ WebInspector.Database.prototype = {
         {
             callback(names.sort());
         }
-        var callId = WebInspector.Callback.wrap(sortingCallback);
-        InspectorBackend.getDatabaseTableNames(callId, this._id);
+        InspectorBackend.getDatabaseTableNames(this._id, sortingCallback);
     },
     
     executeSql: function(query, onSuccess, onError)
@@ -99,7 +98,7 @@ WebInspector.Database.prototype = {
             WebInspector.Database.successCallbacks[transactionId] = onSuccess;
             WebInspector.Database.errorCallbacks[transactionId] = onError;
         }
-        InspectorBackend.executeSQL(WebInspector.Callback.wrap(callback), this._id, query);
+        InspectorBackend.executeSQL(this._id, query, callback);
     }
 }
 
diff --git a/WebCore/inspector/front-end/ElementsPanel.js b/WebCore/inspector/front-end/ElementsPanel.js
index f18299a..d81933e 100644
--- a/WebCore/inspector/front-end/ElementsPanel.js
+++ b/WebCore/inspector/front-end/ElementsPanel.js
@@ -224,10 +224,9 @@ WebInspector.ElementsPanel.prototype = {
             selectNode.call(this, node);
         }
 
-        if (this._selectedPathOnReset) {
-            var callId = WebInspector.Callback.wrap(selectLastSelectedNode.bind(this));
-            InspectorBackend.pushNodeByPathToFrontend(callId, this._selectedPathOnReset.join(","));
-        } else
+        if (this._selectedPathOnReset)
+            InspectorBackend.pushNodeByPathToFrontend(this._selectedPathOnReset.join(","), selectLastSelectedNode.bind(this));
+        else
             selectNode.call(this);
         delete this._selectedPathOnReset;
     },
diff --git a/WebCore/inspector/front-end/ElementsTreeOutline.js b/WebCore/inspector/front-end/ElementsTreeOutline.js
index 7f48161..ae9e40a 100644
--- a/WebCore/inspector/front-end/ElementsTreeOutline.js
+++ b/WebCore/inspector/front-end/ElementsTreeOutline.js
@@ -1125,8 +1125,7 @@ WebInspector.ElementsTreeElement.prototype = {
             moveToNextAttributeIfNeeded.call(newTreeItem);
         }
 
-        var callId = WebInspector.Callback.wrap(changeTagNameCallback);
-        InspectorBackend.changeTagName(callId, this.representedObject.id, newText);
+        InspectorBackend.changeTagName(this.representedObject.id, newText, changeTagNameCallback);
     },
 
     _textNodeEditingCommitted: function(element, newText)
@@ -1374,8 +1373,7 @@ WebInspector.ElementsTreeElement.prototype = {
             parentElement.adjustCollapsedRange(true);
         }
 
-        var callId = WebInspector.Callback.wrap(removeNodeCallback);
-        InspectorBackend.removeNode(callId, this.representedObject.id);
+        InspectorBackend.removeNode(this.representedObject.id, removeNodeCallback);
     },
 
     _editAsHTML: function()
@@ -1402,12 +1400,10 @@ WebInspector.ElementsTreeElement.prototype = {
 
         function commitChange(value)
         {
-            var setCallId = WebInspector.Callback.wrap(selectNode);
-            InspectorBackend.setOuterHTML(setCallId, node.id, value);
+            InspectorBackend.setOuterHTML(node.id, value, selectNode);
         }
 
-        var getCallId = WebInspector.Callback.wrap(this._startEditingAsHTML.bind(this, commitChange));
-        InspectorBackend.getOuterHTML(getCallId, node.id);
+        InspectorBackend.getOuterHTML(node.id, this._startEditingAsHTML.bind(this, commitChange));
     },
 
     _copyHTML: function()
diff --git a/WebCore/inspector/front-end/InjectedScriptAccess.js b/WebCore/inspector/front-end/InjectedScriptAccess.js
index ce264dd..cb3c2b8 100644
--- a/WebCore/inspector/front-end/InjectedScriptAccess.js
+++ b/WebCore/inspector/front-end/InjectedScriptAccess.js
@@ -76,9 +76,7 @@ InjectedScriptAccess._installHandler = function(methodName, async)
             else
                 WebInspector.console.addMessage(WebInspector.ConsoleMessage.createTextMessage("Error dispatching: " + methodName));
         }
-        var callId = WebInspector.Callback.wrap(myCallback);
-
-        InspectorBackend.dispatchOnInjectedScript(callId, this._worldId, methodName, argsString);
+        InspectorBackend.dispatchOnInjectedScript(this._worldId, methodName, argsString, myCallback);
     };
 }
 
diff --git a/WebCore/inspector/front-end/MetricsSidebarPane.js b/WebCore/inspector/front-end/MetricsSidebarPane.js
index ed5a7ec..18bc240 100644
--- a/WebCore/inspector/front-end/MetricsSidebarPane.js
+++ b/WebCore/inspector/front-end/MetricsSidebarPane.js
@@ -52,14 +52,14 @@ WebInspector.MetricsSidebarPane.prototype = {
             var style = WebInspector.CSSStyleDeclaration.parseStyle(stylePayload);
             self._update(style);
         };
-        InspectorBackend.getComputedStyle(WebInspector.Callback.wrap(callback), node.id);
+        InspectorBackend.getComputedStyle(node.id, callback);
 
         var inlineStyleCallback = function(stylePayload) {
             if (!stylePayload)
                 return;
             self._inlineStyleId = stylePayload.id;
         };
-        InspectorBackend.getInlineStyle(WebInspector.Callback.wrap(inlineStyleCallback), node.id);
+        InspectorBackend.getInlineStyle(node.id, inlineStyleCallback);
     },
 
     _update: function(style)
@@ -210,7 +210,7 @@ WebInspector.MetricsSidebarPane.prototype = {
             self.update();
         };
 
-        InspectorBackend.setStyleProperty(WebInspector.Callback.wrap(callback), this._inlineStyleId, context.styleProperty, userInput);
+        InspectorBackend.setStyleProperty(this._inlineStyleId, context.styleProperty, userInput, callback);
     }
 }
 
diff --git a/WebCore/inspector/front-end/ProfileView.js b/WebCore/inspector/front-end/ProfileView.js
index 817f1f5..ca271d0 100644
--- a/WebCore/inspector/front-end/ProfileView.js
+++ b/WebCore/inspector/front-end/ProfileView.js
@@ -94,8 +94,7 @@ WebInspector.CPUProfileView = function(profile)
         self._updatePercentButton();
     }
 
-    var callId = WebInspector.Callback.wrap(profileCallback);
-    InspectorBackend.getProfile(callId, this.profile.uid);
+    InspectorBackend.getProfile(this.profile.uid, profileCallback);
 }
 
 WebInspector.CPUProfileView.prototype = {
diff --git a/WebCore/inspector/front-end/ProfilesPanel.js b/WebCore/inspector/front-end/ProfilesPanel.js
index e18274c..2174b87 100644
--- a/WebCore/inspector/front-end/ProfilesPanel.js
+++ b/WebCore/inspector/front-end/ProfilesPanel.js
@@ -524,8 +524,7 @@ WebInspector.ProfilesPanel.prototype = {
                 WebInspector.addProfileHeader(profileHeaders[i]);
         }
 
-        var callId = WebInspector.Callback.wrap(populateCallback);
-        InspectorBackend.getProfileHeaders(callId);
+        InspectorBackend.getProfileHeaders(populateCallback);
 
         this._profilesWereRequested = true;
     },
diff --git a/WebCore/inspector/front-end/ResourcesPanel.js b/WebCore/inspector/front-end/ResourcesPanel.js
index ff0d1ab..27df5cf 100644
--- a/WebCore/inspector/front-end/ResourcesPanel.js
+++ b/WebCore/inspector/front-end/ResourcesPanel.js
@@ -883,7 +883,7 @@ WebInspector.ResourcesPanel.prototype.__proto__ = WebInspector.AbstractTimelineP
 
 WebInspector.getResourceContent = function(identifier, callback)
 {
-    InspectorBackend.getResourceContent(WebInspector.Callback.wrap(callback), identifier);
+    InspectorBackend.getResourceContent(identifier, callback);
 }
 
 WebInspector.ResourceTimeCalculator = function(startAtZero)
diff --git a/WebCore/inspector/front-end/ScriptView.js b/WebCore/inspector/front-end/ScriptView.js
index 74dc30a..d878e9b 100644
--- a/WebCore/inspector/front-end/ScriptView.js
+++ b/WebCore/inspector/front-end/ScriptView.js
@@ -56,10 +56,8 @@ WebInspector.ScriptView.prototype = {
 
         if (this.script.source)
             this._sourceFrameSetupFinished();
-        else {
-            var callbackId = WebInspector.Callback.wrap(this._didGetScriptSource.bind(this))
-            InspectorBackend.getScriptSource(callbackId, this.script.sourceID);
-        }
+        else
+            InspectorBackend.getScriptSource(this.script.sourceID, this._didGetScriptSource.bind(this));
     },
 
     _didGetScriptSource: function(source)
diff --git a/WebCore/inspector/front-end/ScriptsPanel.js b/WebCore/inspector/front-end/ScriptsPanel.js
index 7521ea9..75fd6f7 100644
--- a/WebCore/inspector/front-end/ScriptsPanel.js
+++ b/WebCore/inspector/front-end/ScriptsPanel.js
@@ -343,8 +343,7 @@ WebInspector.ScriptsPanel.prototype = {
                 WebInspector.breakpointManager.setBreakpoint(sourceID, breakpoint.url, newLine, breakpoint.enabled, breakpoint.condition);
             }
         };
-        var callbackId = WebInspector.Callback.wrap(mycallback.bind(this))
-        InspectorBackend.editScriptSource(callbackId, sourceID, newContent);
+        InspectorBackend.editScriptSource(sourceID, newContent, mycallback.bind(this));
     },
 
     selectedCallFrameId: function()
diff --git a/WebCore/inspector/front-end/Settings.js b/WebCore/inspector/front-end/Settings.js
index 33a1b91..41d82f9 100644
--- a/WebCore/inspector/front-end/Settings.js
+++ b/WebCore/inspector/front-end/Settings.js
@@ -81,10 +81,10 @@ WebInspector.Settings.initialize = function()
         WebInspector.sessionSettings.dispatchEventToListeners("loaded");
     }
 
-    InspectorBackend.getSettings(WebInspector.Callback.wrap(function(settings) {
+    InspectorBackend.getSettings(function(settings) {
         populateApplicationSettings(settings.application);
         populateSessionSettings(settings.session);
-    }));
+    });
 }
 
 WebInspector.Settings.prototype = {
diff --git a/WebCore/inspector/front-end/inspector.js b/WebCore/inspector/front-end/inspector.js
index db89e20..2e2c54f 100644
--- a/WebCore/inspector/front-end/inspector.js
+++ b/WebCore/inspector/front-end/inspector.js
@@ -583,7 +583,7 @@ WebInspector.doLoadedDone = function()
     InspectorBackend.populateScriptObjects();
 
     // As a DOMAgent method, this needs to happen after the frontend has loaded and the agent is available.
-    InspectorBackend.getSupportedCSSProperties(WebInspector.Callback.wrap(WebInspector.CSSCompletions._load));
+    InspectorBackend.getSupportedCSSProperties(WebInspector.CSSCompletions._load);
 }
 
 WebInspector.addPanelToolbarIcon = function(toolbarElement, panel, previousToolbarItem)
@@ -632,17 +632,22 @@ WebInspector.dispatch = function(message) {
 WebInspector_syncDispatch = function(message)
 {
     var messageObject = (typeof message === "string") ? JSON.parse(message) : message;
-    if (messageObject.type === "response" && !messageObject.success) {
-        WebInspector.removeResponseCallbackEntry(messageObject.seq)
-        WebInspector.reportProtocolError(messageObject);
-        return;
-    }
 
     var arguments = [];
     if (messageObject.data)
         for (var key in messageObject.data)
             arguments.push(messageObject.data[key]);
 
+    if ("seq" in messageObject) { // just a response for some request
+        if (messageObject.success)
+            WebInspector.processResponse(messageObject.seq, arguments);
+        else {
+            WebInspector.removeResponseCallbackEntry(messageObject.seq)
+            WebInspector.reportProtocolError(messageObject);
+        }
+        return;
+    }
+
     if (messageObject.type === "event") {
         if (!messageObject.event in WebInspector) {
             console.error("Attempted to dispatch unimplemented WebInspector method: %s", messageObject.event);
@@ -650,9 +655,6 @@ WebInspector_syncDispatch = function(message)
         }
         WebInspector[messageObject.event].apply(WebInspector, arguments);
     }
-
-    if (messageObject.type === "response")
-        WebInspector.processResponse(messageObject.seq, arguments);
 }
 
 WebInspector.dispatchMessageFromBackend = function(messageObject)
@@ -662,7 +664,7 @@ WebInspector.dispatchMessageFromBackend = function(messageObject)
 
 WebInspector.reportProtocolError = function(messageObject)
 {
-    console.error("Error: InspectorBackend." + messageObject.command + " failed.");
+    console.error("Error: InspectorBackend request with seq = " + messageObject.seq + " failed.");
     for (var error in messageObject.errors)
         console.error("    " + error);
     WebInspector.removeResponseCallbackEntry(messageObject.seq);
diff --git a/WebKit/chromium/ChangeLog b/WebKit/chromium/ChangeLog
index 6b0b3fa..38a9f34 100644
--- a/WebKit/chromium/ChangeLog
+++ b/WebKit/chromium/ChangeLog
@@ -1,3 +1,16 @@
+2010-08-25  Ilya Tikhonovsky  <loislo at chromium.org>
+
+        Reviewed by Pavel Feldman.
+
+        WebInspector: as far as we have 'seq' property in the each inspector message
+        it would be better to remove explicit callId argument from Inspector.idl functions
+        declarations.
+        https://bugs.webkit.org/show_bug.cgi?id=44617
+
+        * src/js/ProfilerAgent.js:
+        (devtools.ProfilerAgent.prototype._getNextLogLines.else.delayedRequest):
+        (devtools.ProfilerAgent.prototype._getNextLogLines):
+
 2010-08-25  Sheriff Bot  <webkit.review.bot at gmail.com>
 
         Unreviewed, rolling out r66074.
diff --git a/WebKit/chromium/src/js/ProfilerAgent.js b/WebKit/chromium/src/js/ProfilerAgent.js
index 7f74595..c993e62 100644
--- a/WebKit/chromium/src/js/ProfilerAgent.js
+++ b/WebKit/chromium/src/js/ProfilerAgent.js
@@ -91,13 +91,12 @@ devtools.ProfilerAgent.prototype._getNextLogLines = function(immediately)
         return;
     var pos = this._lastRequestedLogPosition = this._logPosition;
 
-    var callId = WebInspector.Callback.wrap(this._didGetProfilerLogLines.bind(this));
     if (immediately)
-        InspectorBackend.getProfilerLogLines(callId, pos);
+        InspectorBackend.getProfilerLogLines(pos, this._didGetProfilerLogLines.bind(this));
     else {
         function delayedRequest()
         {
-            InspectorBackend.getProfilerLogLines(callId, pos);
+            InspectorBackend.getProfilerLogLines(pos, this._didGetProfilerLogLines.bind(this));
         }
         setTimeout(delayedRequest, 500);
     }

-- 
WebKit Debian packaging



More information about the Pkg-webkit-commits mailing list