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

Side by Side Diff: third_party/WebKit/Source/devtools/front_end/console/ConsoleViewMessage.js

Issue 2863183003: DevTools: report adding mutation event listener as a violations. (Closed)
Patch Set: same Created 3 years, 7 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
« no previous file with comments | « third_party/WebKit/Source/core/inspector/InspectorLogAgent.cpp ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2011 Google Inc. All rights reserved. 2 * Copyright (C) 2011 Google Inc. All rights reserved.
3 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved. 3 * Copyright (C) 2007, 2008 Apple Inc. All rights reserved.
4 * Copyright (C) 2009 Joseph Pecoraro 4 * Copyright (C) 2009 Joseph Pecoraro
5 * 5 *
6 * Redistribution and use in source and binary forms, with or without 6 * Redistribution and use in source and binary forms, with or without
7 * modification, are permitted provided that the following conditions 7 * modification, are permitted provided that the following conditions
8 * are met: 8 * are met:
9 * 9 *
10 * 1. Redistributions of source code must retain the above copyright 10 * 1. Redistributions of source code must retain the above copyright
(...skipping 875 matching lines...) Expand 10 before | Expand all | Expand 10 after
886 if (this._messageLevelIcon) 886 if (this._messageLevelIcon)
887 contentElement.appendChild(this._messageLevelIcon); 887 contentElement.appendChild(this._messageLevelIcon);
888 this._contentElement = contentElement; 888 this._contentElement = contentElement;
889 if (this._message.type === ConsoleModel.ConsoleMessage.MessageType.StartGrou p || 889 if (this._message.type === ConsoleModel.ConsoleMessage.MessageType.StartGrou p ||
890 this._message.type === ConsoleModel.ConsoleMessage.MessageType.StartGrou pCollapsed) 890 this._message.type === ConsoleModel.ConsoleMessage.MessageType.StartGrou pCollapsed)
891 contentElement.classList.add('console-group-title'); 891 contentElement.classList.add('console-group-title');
892 892
893 var formattedMessage; 893 var formattedMessage;
894 var shouldIncludeTrace = !!this._message.stackTrace && 894 var shouldIncludeTrace = !!this._message.stackTrace &&
895 (this._message.source === ConsoleModel.ConsoleMessage.MessageSource.Netw ork || 895 (this._message.source === ConsoleModel.ConsoleMessage.MessageSource.Netw ork ||
896 this._message.source === ConsoleModel.ConsoleMessage.MessageSource.Viol ation ||
896 this._message.level === ConsoleModel.ConsoleMessage.MessageLevel.Error || 897 this._message.level === ConsoleModel.ConsoleMessage.MessageLevel.Error ||
897 this._message.type === ConsoleModel.ConsoleMessage.MessageType.Trace || 898 this._message.level === ConsoleModel.ConsoleMessage.MessageLevel.Warnin g ||
898 this._message.level === ConsoleModel.ConsoleMessage.MessageLevel.Warnin g); 899 this._message.type === ConsoleModel.ConsoleMessage.MessageType.Trace);
899 if (this._message.runtimeModel() && shouldIncludeTrace) 900 if (this._message.runtimeModel() && shouldIncludeTrace)
900 formattedMessage = this._buildMessageWithStackTrace(); 901 formattedMessage = this._buildMessageWithStackTrace();
901 else if (this._message.type === ConsoleModel.ConsoleMessage.MessageType.Tabl e) 902 else if (this._message.type === ConsoleModel.ConsoleMessage.MessageType.Tabl e)
902 formattedMessage = this._buildTableMessage(); 903 formattedMessage = this._buildTableMessage();
903 else 904 else
904 formattedMessage = this._buildMessage(); 905 formattedMessage = this._buildMessage();
905 contentElement.appendChild(formattedMessage); 906 contentElement.appendChild(formattedMessage);
906 907
907 this.updateTimestamp(); 908 this.updateTimestamp();
908 return this._contentElement; 909 return this._contentElement;
(...skipping 306 matching lines...) Expand 10 before | Expand all | Expand 10 after
1215 toMessageElement() { 1216 toMessageElement() {
1216 if (!this._element) { 1217 if (!this._element) {
1217 super.toMessageElement(); 1218 super.toMessageElement();
1218 this._expandGroupIcon = UI.Icon.create('', 'expand-group-icon'); 1219 this._expandGroupIcon = UI.Icon.create('', 'expand-group-icon');
1219 this._contentElement.insertBefore(this._expandGroupIcon, this._contentElem ent.firstChild); 1220 this._contentElement.insertBefore(this._expandGroupIcon, this._contentElem ent.firstChild);
1220 this.setCollapsed(this._collapsed); 1221 this.setCollapsed(this._collapsed);
1221 } 1222 }
1222 return this._element; 1223 return this._element;
1223 } 1224 }
1224 }; 1225 };
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/core/inspector/InspectorLogAgent.cpp ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698