Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(152)

Side by Side Diff: third_party/WebKit/Source/platform/v8_inspector/V8RuntimeAgentImpl.cpp

Issue 2102453003: [DevTools] Move collectionEntries to internalProperties in protocol (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 5 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions are 5 * modification, are permitted provided that the following conditions are
6 * met: 6 * met:
7 * 7 *
8 * * Redistributions of source code must retain the above copyright 8 * * Redistributions of source code must retain the above copyright
9 * notice, this list of conditions and the following disclaimer. 9 * notice, this list of conditions and the following disclaimer.
10 * * Redistributions in binary form must reproduce the above 10 * * Redistributions in binary form must reproduce the above
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
211 if (!scope.object()->IsObject()) { 211 if (!scope.object()->IsObject()) {
212 *errorString = "Value with given id is not an object"; 212 *errorString = "Value with given id is not an object";
213 return; 213 return;
214 } 214 }
215 215
216 v8::Local<v8::Object> object = scope.object().As<v8::Object>(); 216 v8::Local<v8::Object> object = scope.object().As<v8::Object>();
217 scope.injectedScript()->getProperties(errorString, object, scope.objectGroup Name(), ownProperties.fromMaybe(false), accessorPropertiesOnly.fromMaybe(false), generatePreview.fromMaybe(false), result, exceptionDetails); 217 scope.injectedScript()->getProperties(errorString, object, scope.objectGroup Name(), ownProperties.fromMaybe(false), accessorPropertiesOnly.fromMaybe(false), generatePreview.fromMaybe(false), result, exceptionDetails);
218 if (!errorString->isEmpty() || exceptionDetails->isJust() || accessorPropert iesOnly.fromMaybe(false)) 218 if (!errorString->isEmpty() || exceptionDetails->isJust() || accessorPropert iesOnly.fromMaybe(false))
219 return; 219 return;
220 v8::Local<v8::Array> propertiesArray; 220 v8::Local<v8::Array> propertiesArray;
221 if (hasInternalError(errorString, !v8::Debug::GetInternalProperties(m_debugg er->isolate(), scope.object()).ToLocal(&propertiesArray))) 221 if (hasInternalError(errorString, !m_debugger->internalProperties(scope.cont ext(), scope.object()).ToLocal(&propertiesArray)))
222 return; 222 return;
223 std::unique_ptr<protocol::Array<InternalPropertyDescriptor>> propertiesProto colArray = protocol::Array<InternalPropertyDescriptor>::create(); 223 std::unique_ptr<protocol::Array<InternalPropertyDescriptor>> propertiesProto colArray = protocol::Array<InternalPropertyDescriptor>::create();
224 for (uint32_t i = 0; i < propertiesArray->Length(); i += 2) { 224 for (uint32_t i = 0; i < propertiesArray->Length(); i += 2) {
225 v8::Local<v8::Value> name; 225 v8::Local<v8::Value> name;
226 if (hasInternalError(errorString, !propertiesArray->Get(scope.context(), i).ToLocal(&name)) || !name->IsString()) 226 if (hasInternalError(errorString, !propertiesArray->Get(scope.context(), i).ToLocal(&name)) || !name->IsString())
227 return; 227 return;
228 v8::Local<v8::Value> value; 228 v8::Local<v8::Value> value;
229 if (hasInternalError(errorString, !propertiesArray->Get(scope.context(), i + 1).ToLocal(&value))) 229 if (hasInternalError(errorString, !propertiesArray->Get(scope.context(), i + 1).ToLocal(&value)))
230 return; 230 return;
231 std::unique_ptr<RemoteObject> wrappedValue = scope.injectedScript()->wra pObject(errorString, value, scope.objectGroupName()); 231 std::unique_ptr<RemoteObject> wrappedValue = scope.injectedScript()->wra pObject(errorString, value, scope.objectGroupName());
(...skipping 180 matching lines...) Expand 10 before | Expand all | Expand 10 after
412 } 412 }
413 } 413 }
414 414
415 void V8RuntimeAgentImpl::inspect(std::unique_ptr<protocol::Runtime::RemoteObject > objectToInspect, std::unique_ptr<protocol::DictionaryValue> hints) 415 void V8RuntimeAgentImpl::inspect(std::unique_ptr<protocol::Runtime::RemoteObject > objectToInspect, std::unique_ptr<protocol::DictionaryValue> hints)
416 { 416 {
417 if (m_enabled) 417 if (m_enabled)
418 m_frontend.inspectRequested(std::move(objectToInspect), std::move(hints) ); 418 m_frontend.inspectRequested(std::move(objectToInspect), std::move(hints) );
419 } 419 }
420 420
421 } // namespace blink 421 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698