Changeset 65052 in webkit


Ignore:
Timestamp:
Aug 9, 2010 10:50:52 PM (14 years ago)
Author:
loislo@chromium.org
Message:

2010-08-09 Ilya Tikhonovsky <loislo@chromium.org>

Reviewed by Pavel Feldman.

Web Inspector: Remove obsolete JS wrappers for did* methods.
https://bugs.webkit.org/show_bug.cgi?id=43738

  • inspector/CodeGeneratorInspector.pm:
  • inspector/Inspector.idl:
  • inspector/front-end/BreakpointManager.js:
  • inspector/front-end/Callback.js:
  • inspector/front-end/ConsoleView.js:
  • inspector/front-end/DOMAgent.js:
  • inspector/front-end/DOMStorage.js:
  • inspector/front-end/Database.js:
  • inspector/front-end/InjectedScriptAccess.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: (WebInspector.reportProtocolError):
Location:
trunk/WebCore
Files:
15 edited

Legend:

Unmodified
Added
Removed
  • trunk/WebCore/ChangeLog

    r65046 r65052  
     12010-08-09  Ilya Tikhonovsky  <loislo@chromium.org>
     2
     3        Reviewed by Pavel Feldman.
     4
     5        Web Inspector: Remove obsolete JS wrappers for did* methods.
     6        https://bugs.webkit.org/show_bug.cgi?id=43738
     7
     8        * inspector/CodeGeneratorInspector.pm:
     9        * inspector/Inspector.idl:
     10        * inspector/front-end/BreakpointManager.js:
     11        * inspector/front-end/Callback.js:
     12        * inspector/front-end/ConsoleView.js:
     13        * inspector/front-end/DOMAgent.js:
     14        * inspector/front-end/DOMStorage.js:
     15        * inspector/front-end/Database.js:
     16        * inspector/front-end/InjectedScriptAccess.js:
     17        * inspector/front-end/ProfilesPanel.js:
     18        * inspector/front-end/ResourcesPanel.js:
     19        * inspector/front-end/ScriptView.js:
     20        * inspector/front-end/ScriptsPanel.js:
     21        * inspector/front-end/inspector.js:
     22        (WebInspector.reportProtocolError):
     23
    1242010-08-09  Gavin Barraclough  <barraclough@apple.com>
    225
  • trunk/WebCore/inspector/CodeGeneratorInspector.pm

    r65021 r65052  
    241241    my $async = $function->signature->extendedAttributes->{"async"};
    242242    return if !$async && !$notify;
    243     my $functionName;
    244     if ($notify) {
    245         $functionName = $function->signature->name;
    246     } else {
    247         my $customResponse = $function->signature->extendedAttributes->{"customResponse"};
    248         $functionName = $customResponse ? $customResponse : "did" . ucfirst($function->signature->name);
    249     }
     243    my $functionName = $notify ? $function->signature->name : "did" . ucfirst($function->signature->name);
    250244
    251245    my @argsFiltered = grep($_->direction eq "out", @{$function->parameters}); # just keep only out parameters for frontend interface.
     
    263257        push(@function, "{");
    264258        push(@function, "    RefPtr<InspectorArray> arguments = InspectorArray::create();");
    265         push(@function, "    arguments->pushString(\"$functionName\");");
     259        push(@function, "    arguments->pushString(\"" . ($notify ? $functionName : "processResponse") . "\");");
    266260        push(@function, @pushArguments);
    267261        push(@function, "    m_inspectorClient->sendMessageToFrontend(arguments->toJSONString());");
     262
    268263        push(@function, "}");
    269264        push(@function, "");
     
    355350    if (scalar(grep($_->name eq "callId", @inArgs)) && !$async) {
    356351        my @pushArguments = map("        arguments->push" . $typeTransform{$_->type}->{"accessorSuffix"} . "(" . $_->name . ");", @outArgs);
    357         my $customResponse = $function->signature->extendedAttributes->{"customResponse"};
    358         my $didFunctionName = $customResponse ? $customResponse : "did" . ucfirst($function->signature->name);
    359352
    360353        push(@function, "");
     
    362355        push(@function, "    if (m_inspectorController->remoteInspectorFrontend()) {");
    363356        push(@function, "        RefPtr<InspectorArray> arguments = InspectorArray::create();");
    364         push(@function, "        arguments->pushString(\"$didFunctionName\");");
     357        push(@function, "        arguments->pushString(\"processResponse\");");
    365358        push(@function, "        arguments->pushNumber(callId);");
    366359        push(@function, @pushArguments);
  • trunk/WebCore/inspector/Inspector.idl

    r64973 r65052  
    163163
    164164        [handler=DOM] void getChildNodes(in long callId, in long nodeId);
    165         [handler=DOM, customResponse=didApplyDomChange] void setAttribute(in long callId, in long elementId, in String name, in String value, out boolean success);
    166         [handler=DOM, customResponse=didApplyDomChange] void removeAttribute(in long callId, in long elementId, in String name, out boolean success);
    167         [handler=DOM, customResponse=didApplyDomChange] void setTextNodeValue(in long callId, in long nodeId, in String value, out boolean success);
     165        [handler=DOM] void setAttribute(in long callId, in long elementId, in String name, in String value, out boolean success);
     166        [handler=DOM] void removeAttribute(in long callId, in long elementId, in String name, out boolean success);
     167        [handler=DOM] void setTextNodeValue(in long callId, in long nodeId, in String value, out boolean success);
    168168        [handler=DOM] void getEventListenersForNode(in long callId, in long nodeId, out long outNodeId, out Array listenersArray);
    169169        [handler=DOM] void copyNode(in long nodeId);
  • trunk/WebCore/inspector/front-end/BreakpointManager.js

    r62095 r65052  
    214214WebInspector.Breakpoint.prototype.__proto__ = WebInspector.Object.prototype;
    215215
    216 WebInspector.didSetBreakpoint = WebInspector.Callback.processCallback;
  • trunk/WebCore/inspector/front-end/Callback.js

    r64770 r65052  
    4343    },
    4444
    45     processCallback: function(callbackId, opt_vararg)
     45    processResponse: function(callbackId, opt_vararg)
    4646    {
    4747        var args = Array.prototype.slice.call(arguments, 1);
     
    5151    },
    5252
    53     removeCallbackEntry: function(callbackId)
     53    removeResponseCallbackEntry: function(callbackId)
    5454    {
    5555        delete this._callbacks[callbackId];
     
    5959WebInspector.Callback._INSTANCE = new WebInspector.Callback();
    6060WebInspector.Callback.wrap = WebInspector.Callback._INSTANCE.wrap.bind(WebInspector.Callback._INSTANCE);
    61 WebInspector.Callback.processCallback = WebInspector.Callback._INSTANCE.processCallback.bind(WebInspector.Callback._INSTANCE);
    62 WebInspector.Callback.removeCallbackEntry = WebInspector.Callback._INSTANCE.removeCallbackEntry.bind(WebInspector.Callback._INSTANCE);
     61WebInspector.processResponse = WebInspector.Callback._INSTANCE.processResponse.bind(WebInspector.Callback._INSTANCE);
     62WebInspector.removeResponseCallbackEntry = WebInspector.Callback._INSTANCE.removeResponseCallbackEntry.bind(WebInspector.Callback._INSTANCE);
  • trunk/WebCore/inspector/front-end/ConsoleView.js

    r63891 r65052  
    11291129}
    11301130
    1131 WebInspector.didClearConsoleMessages = WebInspector.Callback.processCallback;
  • trunk/WebCore/inspector/front-end/DOMAgent.js

    r63886 r65052  
    682682}
    683683
    684 WebInspector.didGetApplicationCaches = WebInspector.Callback.processCallback;
    685 WebInspector.didGetCookies = WebInspector.Callback.processCallback;
    686 WebInspector.didGetChildNodes = WebInspector.Callback.processCallback;
    687 WebInspector.didPerformSearch = WebInspector.Callback.processCallback;
    688 WebInspector.didApplyDomChange = WebInspector.Callback.processCallback;
    689 WebInspector.didRemoveAttribute = WebInspector.Callback.processCallback;
    690 WebInspector.didSetTextNodeValue = WebInspector.Callback.processCallback;
    691 WebInspector.didRemoveNode = WebInspector.Callback.processCallback;
    692 WebInspector.didChangeTagName = WebInspector.Callback.processCallback;
    693 WebInspector.didGetOuterHTML = WebInspector.Callback.processCallback;
    694 WebInspector.didSetOuterHTML = WebInspector.Callback.processCallback;
    695 WebInspector.didPushNodeByPathToFrontend = WebInspector.Callback.processCallback;
    696 WebInspector.didGetEventListenersForNode = WebInspector.Callback.processCallback;
    697 
    698 WebInspector.didGetStyles = WebInspector.Callback.processCallback;
    699 WebInspector.didGetAllStyles = WebInspector.Callback.processCallback;
    700 WebInspector.didGetStyleSheet = WebInspector.Callback.processCallback;
    701 WebInspector.didGetRuleRanges = WebInspector.Callback.processCallback;
    702 WebInspector.didGetInlineStyle = WebInspector.Callback.processCallback;
    703 WebInspector.didGetComputedStyle = WebInspector.Callback.processCallback;
    704 WebInspector.didApplyStyleText = WebInspector.Callback.processCallback;
    705 WebInspector.didSetStyleText = WebInspector.Callback.processCallback;
    706 WebInspector.didSetStyleProperty = WebInspector.Callback.processCallback;
    707 WebInspector.didToggleStyleEnabled = WebInspector.Callback.processCallback;
    708 WebInspector.didSetRuleSelector = WebInspector.Callback.processCallback;
    709 WebInspector.didAddRule = WebInspector.Callback.processCallback;
  • trunk/WebCore/inspector/front-end/DOMStorage.js

    r51528 r65052  
    7474}
    7575
    76 WebInspector.didGetDOMStorageEntries = WebInspector.Callback.processCallback;
    77 WebInspector.didSetDOMStorageItem = WebInspector.Callback.processCallback;
    78 WebInspector.didRemoveDOMStorageItem = WebInspector.Callback.processCallback;
  • trunk/WebCore/inspector/front-end/Database.js

    r53766 r65052  
    101101}
    102102
    103 WebInspector.didGetDatabaseTableNames = WebInspector.Callback.processCallback;
  • trunk/WebCore/inspector/front-end/InjectedScriptAccess.js

    r64458 r65052  
    9090InjectedScriptAccess._installHandler("executeSql", true);
    9191
    92 WebInspector.didDispatchOnInjectedScript = WebInspector.Callback.processCallback;
  • trunk/WebCore/inspector/front-end/ProfilesPanel.js

    r62647 r65052  
    628628WebInspector.ProfileGroupSidebarTreeElement.prototype.__proto__ = WebInspector.SidebarTreeElement.prototype;
    629629
    630 WebInspector.didGetProfileHeaders = WebInspector.Callback.processCallback;
    631 WebInspector.didGetProfile = WebInspector.Callback.processCallback;
  • trunk/WebCore/inspector/front-end/ResourcesPanel.js

    r64144 r65052  
    892892}
    893893
    894 WebInspector.didGetResourceContent = WebInspector.Callback.processCallback;
    895 
    896894WebInspector.ResourceTimeCalculator = function(startAtZero)
    897895{
  • trunk/WebCore/inspector/front-end/ScriptView.js

    r64133 r65052  
    137137WebInspector.ScriptView.prototype.__proto__ = WebInspector.View.prototype;
    138138
    139 WebInspector.didGetScriptSource = WebInspector.Callback.processCallback;
  • trunk/WebCore/inspector/front-end/ScriptsPanel.js

    r64846 r65052  
    10351035WebInspector.ScriptsPanel.prototype.__proto__ = WebInspector.Panel.prototype;
    10361036
    1037 WebInspector.didEditScriptSource = WebInspector.Callback.processCallback;
  • trunk/WebCore/inspector/front-end/inspector.js

    r64978 r65052  
    590590{
    591591    WebInspector.log("InspectorBackend." + methodName + " failed with error text: '" + errorText + "'");
    592     WebInspector.Callback.removeCallbackEntry(callId);
     592    WebInspector.removeResponseCallbackEntry(callId);
    593593}
    594594
Note: See TracChangeset for help on using the changeset viewer.