summaryrefslogtreecommitdiffstats
path: root/WebCore/inspector/front-end/ObjectProxy.js
diff options
context:
space:
mode:
Diffstat (limited to 'WebCore/inspector/front-end/ObjectProxy.js')
-rw-r--r--WebCore/inspector/front-end/ObjectProxy.js18
1 files changed, 18 insertions, 0 deletions
diff --git a/WebCore/inspector/front-end/ObjectProxy.js b/WebCore/inspector/front-end/ObjectProxy.js
index bb4afa5..f4a59a7 100644
--- a/WebCore/inspector/front-end/ObjectProxy.js
+++ b/WebCore/inspector/front-end/ObjectProxy.js
@@ -45,6 +45,24 @@ WebInspector.ObjectProxy.wrapPrimitiveValue = function(value)
return proxy;
}
+WebInspector.ObjectProxy.getPropertiesAsync = function(objectProxy, propertiesToQueryFor, callback)
+{
+ function createPropertiesMapThenCallback(propertiesPayload)
+ {
+ if (!propertiesPayload) {
+ callback();
+ return;
+ }
+
+ var result = [];
+ for (var i = 0; i < propertiesPayload.length; ++i)
+ if (propertiesToQueryFor.indexOf(propertiesPayload[i].name) !== -1)
+ result[propertiesPayload[i].name] = propertiesPayload[i].value.description;
+ callback(result);
+ };
+ InjectedScriptAccess.getProperties(objectProxy, true, createPropertiesMapThenCallback);
+}
+
WebInspector.ObjectPropertyProxy = function(name, value)
{
this.name = name;