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

Side by Side Diff: third_party/WebKit/public/web/WebConsoleMessage.h

Issue 1890513004: Remove dependency on the DevTools agent for console logs. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase. Created 4 years, 8 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 18 matching lines...) Expand all
29 */ 29 */
30 30
31 #ifndef WebConsoleMessage_h 31 #ifndef WebConsoleMessage_h
32 #define WebConsoleMessage_h 32 #define WebConsoleMessage_h
33 33
34 #include "../platform/WebString.h" 34 #include "../platform/WebString.h"
35 35
36 namespace blink { 36 namespace blink {
37 37
38 struct WebConsoleMessage { 38 struct WebConsoleMessage {
39 enum class Source {
40 XML,
41 JS,
42 Network,
43 ConsoleAPI,
44 Storage,
45 AppCache,
46 Rendering,
47 Security,
48 Other,
49 Deprecation,
50 Last = Deprecation
51 };
52
39 enum Level { 53 enum Level {
40 LevelDebug = 4, 54 LevelDebug = 4,
41 LevelLog = 1, 55 LevelLog = 1,
42 LevelInfo = 5, 56 LevelInfo = 5,
43 LevelWarning = 2, 57 LevelWarning = 2,
44 LevelError = 3, 58 LevelError = 3,
45 LevelRevokedError = 6, 59 LevelRevokedError = 6,
46 LevelLast = LevelInfo 60 LevelLast = LevelInfo
47 }; 61 };
48 62
49 Level level; 63 Level level;
50 WebString text; 64 WebString text;
51 WebString url; 65 WebString url;
66 Source source;
52 unsigned lineNumber; 67 unsigned lineNumber;
53 unsigned columnNumber; 68 unsigned columnNumber;
54 69
55 WebConsoleMessage() 70 WebConsoleMessage()
56 : level(LevelLog) 71 : level(LevelLog)
72 , source(Source::Other)
57 , lineNumber(0) 73 , lineNumber(0)
58 , columnNumber(0) 74 , columnNumber(0)
59 { 75 {
60 } 76 }
61 WebConsoleMessage(Level level, const WebString& text) 77 WebConsoleMessage(Level level, const WebString& text)
62 : level(level) 78 : level(level)
63 , text(text) 79 , text(text)
80 , source(Source::Other)
64 , lineNumber(0) 81 , lineNumber(0)
65 , columnNumber(0) 82 , columnNumber(0)
66 { 83 {
67 } 84 }
68 }; 85 };
69 86
70 } // namespace blink 87 } // namespace blink
71 88
72 #endif 89 #endif
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698