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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/sdk/RemoteObject.js

Issue 2249743006: [DevTools] Fill ExceptionDetails with more details, unify usage across protocol. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: browser test Created 4 years, 4 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) 2009 Google Inc. All rights reserved. 2 * Copyright (C) 2009 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 587 matching lines...) Expand 10 before | Expand all | Expand 10 after
598 * @param {?RuntimeAgent.ExceptionDetails=} exceptionDetails 598 * @param {?RuntimeAgent.ExceptionDetails=} exceptionDetails
599 * @this {WebInspector.RemoteObjectImpl} 599 * @this {WebInspector.RemoteObjectImpl}
600 */ 600 */
601 function remoteObjectBinder(error, properties, internalProperties, excep tionDetails) 601 function remoteObjectBinder(error, properties, internalProperties, excep tionDetails)
602 { 602 {
603 if (error) { 603 if (error) {
604 callback(null, null); 604 callback(null, null);
605 return; 605 return;
606 } 606 }
607 if (exceptionDetails) { 607 if (exceptionDetails) {
608 var msg = new WebInspector.ConsoleMessage(this._target, WebInspe ctor.ConsoleMessage.MessageSource.JS, WebInspector.ConsoleMessage.MessageLevel.E rror, exceptionDetails.text); 608 this._target.consoleModel.addMessage(WebInspector.ConsoleMessage .fromException(this._target, exceptionDetails, undefined, undefined, undefined)) ;
609 this._target.consoleModel.addMessage(msg);
610 callback(null, null); 609 callback(null, null);
611 return; 610 return;
612 } 611 }
613 var result = []; 612 var result = [];
614 for (var i = 0; properties && i < properties.length; ++i) { 613 for (var i = 0; properties && i < properties.length; ++i) {
615 var property = properties[i]; 614 var property = properties[i];
616 var propertyValue = property.value ? this._target.runtimeModel.c reateRemoteObject(property.value) : null; 615 var propertyValue = property.value ? this._target.runtimeModel.c reateRemoteObject(property.value) : null;
617 var propertySymbol = property.symbol ? this._target.runtimeModel .createRemoteObject(property.symbol) : null; 616 var propertySymbol = property.symbol ? this._target.runtimeModel .createRemoteObject(property.symbol) : null;
618 var remoteProperty = new WebInspector.RemoteObjectProperty(prope rty.name, propertyValue, 617 var remoteProperty = new WebInspector.RemoteObjectProperty(prope rty.name, propertyValue,
619 !!property.enumerable, !!property.writable, !!property.i sOwn, !!property.wasThrown, propertySymbol); 618 !!property.enumerable, !!property.writable, !!property.i sOwn, !!property.wasThrown, propertySymbol);
(...skipping 891 matching lines...) Expand 10 before | Expand all | Expand 10 after
1511 }, 1510 },
1512 1511
1513 /** 1512 /**
1514 * @return {!WebInspector.RemoteObject} 1513 * @return {!WebInspector.RemoteObject}
1515 */ 1514 */
1516 object: function() 1515 object: function()
1517 { 1516 {
1518 return this._object; 1517 return this._object;
1519 } 1518 }
1520 } 1519 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698