Chromium Code Reviews| Index: third_party/WebKit/Source/platform/v8_inspector/InjectedScriptSource.js |
| diff --git a/third_party/WebKit/Source/platform/v8_inspector/InjectedScriptSource.js b/third_party/WebKit/Source/platform/v8_inspector/InjectedScriptSource.js |
| index 01a001cc7f5243681427902de53b254fdb16278b..c88899148eb32de197af34be3e884da423c36515 100644 |
| --- a/third_party/WebKit/Source/platform/v8_inspector/InjectedScriptSource.js |
| +++ b/third_party/WebKit/Source/platform/v8_inspector/InjectedScriptSource.js |
| @@ -301,6 +301,22 @@ InjectedScript.prototype = { |
| }, |
| /** |
| + * @param {!Array<!Object>} array |
| + * @param {string} property |
| + * @param {string} groupName |
| + * @param {boolean} canAccessInspectedGlobalObject |
| + * @param {boolean} forceValueType |
| + * @param {boolean} generatePreview |
| + */ |
| + wrapObjectsInArray: function(array, property, groupName, canAccessInspectedGlobalObject, forceValueType, generatePreview) |
| + { |
| + for (var i = 0; i < array.length; ++i) { |
| + if (property in array[i]) |
|
dgozman
2016/03/21 17:21:02
typeof array[i] === "object"
kozy
2016/03/21 19:45:01
Done.
|
| + array[i][property] = this.wrapObject(array[i][property], groupName, canAccessInspectedGlobalObject, forceValueType, generatePreview); |
| + } |
| + }, |
| + |
| + /** |
| * @param {*} object |
| * @return {!RuntimeAgent.RemoteObject} |
| */ |
| @@ -450,30 +466,6 @@ InjectedScript.prototype = { |
| }, |
| /** |
| - * @param {string} objectId |
| - * @return {!Array.<!Object>|string} |
| - */ |
| - getCollectionEntries: function(objectId) |
| - { |
| - var parsedObjectId = this._parseObjectId(objectId); |
| - var object = this._objectForId(parsedObjectId); |
| - if (!object || typeof object !== "object") |
| - return "Could not find object with given id"; |
| - var entries = InjectedScriptHost.collectionEntries(object); |
| - if (!entries) |
| - return "Object with given id is not a collection"; |
| - var objectGroupName = InjectedScriptHost.idToObjectGroupName(parsedObjectId.id); |
| - for (var i = 0; i < entries.length; ++i) { |
| - var entry = nullifyObjectProto(entries[i]); |
| - if ("key" in entry) |
| - entry.key = this._wrapObject(entry.key, objectGroupName); |
| - entry.value = this._wrapObject(entry.value, objectGroupName); |
| - entries[i] = entry; |
| - } |
| - return entries; |
| - }, |
| - |
| - /** |
| * @param {!Object} object |
| * @param {boolean=} ownProperties |
| * @param {boolean=} accessorPropertiesOnly |