Upstream version 9.38.198.0
[platform/framework/web/crosswalk.git] / src / third_party / WebKit / Source / devtools / front_end / profiler / HeapSnapshotProxy.js
index f6871e4..5f0324e 100644 (file)
@@ -40,7 +40,7 @@ WebInspector.HeapSnapshotWorkerProxy = function(eventHandler)
     this._nextCallId = 1;
     this._callbacks = [];
     this._previousCallbacks = [];
-    this._worker = new Worker("profiler/heap_snapshot_worker/HeapSnapshotWorker.js");
+    this._worker = Runtime.startWorker("heap_snapshot_worker");
     this._worker.onmessage = this._messageReceived.bind(this);
 }
 
@@ -159,8 +159,8 @@ WebInspector.HeapSnapshotWorkerProxy.prototype = {
         }
         if (data.error) {
             if (data.errorMethodName)
-                WebInspector.console.log(WebInspector.UIString("An error happened when a call for method '%s' was requested", data.errorMethodName));
-            WebInspector.console.log(data["errorCallStack"]);
+                WebInspector.console.error(WebInspector.UIString("An error occurred when a call to method '%s' was requested", data.errorMethodName));
+            WebInspector.console.error(data["errorCallStack"]);
             delete this._callbacks[data.callId];
             return;
         }
@@ -182,6 +182,7 @@ WebInspector.HeapSnapshotWorkerProxy.prototype = {
 
 /**
  * @constructor
+ * @param {!WebInspector.HeapSnapshotWorkerProxy} worker
  * @param {number} objectId
  */
 WebInspector.HeapSnapshotProxyObject = function(worker, objectId)
@@ -241,6 +242,7 @@ WebInspector.HeapSnapshotProxyObject.prototype = {
  * @constructor
  * @extends {WebInspector.HeapSnapshotProxyObject}
  * @implements {WebInspector.OutputStream}
+ * @param {!WebInspector.HeapSnapshotWorkerProxy} worker
  * @param {number} objectId
  * @param {number} profileUid
  * @param {function(!WebInspector.HeapSnapshotProxy)} snapshotReceivedCallback
@@ -334,11 +336,6 @@ WebInspector.HeapSnapshotProxy.prototype = {
         this.callMethod(callback, "nodeClassName", snapshotObjectId);
     },
 
-    dominatorIdsForNode: function(nodeIndex, callback)
-    {
-        this.callMethod(callback, "dominatorIdsForNode", nodeIndex);
-    },
-
     /**
      * @param {number} nodeIndex
      * @return {!WebInspector.HeapSnapshotProviderProxy}
@@ -395,15 +392,6 @@ WebInspector.HeapSnapshotProxy.prototype = {
         return this.callFactoryMethod(null, "createNodesProviderForClass", WebInspector.HeapSnapshotProviderProxy, className, nodeFilter);
     },
 
-    /**
-     * @param {number} nodeIndex
-     * @return {?WebInspector.HeapSnapshotProviderProxy}
-     */
-    createNodesProviderForDominator: function(nodeIndex)
-    {
-        return this.callFactoryMethod(null, "createNodesProviderForDominator", WebInspector.HeapSnapshotProviderProxy, nodeIndex);
-    },
-
     allocationTracesTops: function(callback)
     {
         this.callMethod(callback, "allocationTracesTops");