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

Side by Side Diff: third_party/WebKit/Source/core/inspector/MainThreadDebugger.h

Issue 2170263002: [DevTools] Pass error object when reporting exceptions. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: worklets! 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) 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 24 matching lines...) Expand all
35 #include "core/CoreExport.h" 35 #include "core/CoreExport.h"
36 #include "core/inspector/InspectorTaskRunner.h" 36 #include "core/inspector/InspectorTaskRunner.h"
37 #include "core/inspector/ThreadDebugger.h" 37 #include "core/inspector/ThreadDebugger.h"
38 #include "platform/heap/Handle.h" 38 #include "platform/heap/Handle.h"
39 #include <memory> 39 #include <memory>
40 #include <v8.h> 40 #include <v8.h>
41 41
42 namespace blink { 42 namespace blink {
43 43
44 class ConsoleMessage; 44 class ConsoleMessage;
45 class ErrorEvent;
45 class LocalFrame; 46 class LocalFrame;
46 class SecurityOrigin; 47 class SecurityOrigin;
47 class SourceLocation; 48 class SourceLocation;
48 49
49 class CORE_EXPORT MainThreadDebugger final : public ThreadDebugger { 50 class CORE_EXPORT MainThreadDebugger final : public ThreadDebugger {
50 WTF_MAKE_NONCOPYABLE(MainThreadDebugger); 51 WTF_MAKE_NONCOPYABLE(MainThreadDebugger);
51 public: 52 public:
52 class ClientMessageLoop { 53 class ClientMessageLoop {
53 USING_FAST_MALLOC(ClientMessageLoop); 54 USING_FAST_MALLOC(ClientMessageLoop);
54 public: 55 public:
(...skipping 13 matching lines...) Expand all
68 bool isPaused() const { return m_paused; } 69 bool isPaused() const { return m_paused; }
69 void setClientMessageLoop(std::unique_ptr<ClientMessageLoop>); 70 void setClientMessageLoop(std::unique_ptr<ClientMessageLoop>);
70 void reportConsoleMessage(ExecutionContext*, ConsoleMessage*) override; 71 void reportConsoleMessage(ExecutionContext*, ConsoleMessage*) override;
71 int contextGroupId(ExecutionContext*) override; 72 int contextGroupId(ExecutionContext*) override;
72 73
73 // TODO(dgozman): by making this method virtual, we can move many methods to ThreadDebugger and avoid some duplication. Should be careful about performance. 74 // TODO(dgozman): by making this method virtual, we can move many methods to ThreadDebugger and avoid some duplication. Should be careful about performance.
74 int contextGroupId(LocalFrame*); 75 int contextGroupId(LocalFrame*);
75 void didClearContextsForFrame(LocalFrame*); 76 void didClearContextsForFrame(LocalFrame*);
76 void contextCreated(ScriptState*, LocalFrame*, SecurityOrigin*); 77 void contextCreated(ScriptState*, LocalFrame*, SecurityOrigin*);
77 void contextWillBeDestroyed(ScriptState*); 78 void contextWillBeDestroyed(ScriptState*);
78 void exceptionThrown(LocalFrame*, const String& errorMessage, std::unique_pt r<SourceLocation>); 79 void exceptionThrown(ExecutionContext*, ErrorEvent*);
79 80
80 void installAdditionalCommandLineAPI(v8::Local<v8::Context>, v8::Local<v8::O bject>) override; 81 void installAdditionalCommandLineAPI(v8::Local<v8::Context>, v8::Local<v8::O bject>) override;
81 82
82 v8::MaybeLocal<v8::Value> memoryInfo(v8::Isolate*, v8::Local<v8::Context>) o verride; 83 v8::MaybeLocal<v8::Value> memoryInfo(v8::Isolate*, v8::Local<v8::Context>) o verride;
83 84
84 private: 85 private:
85 // V8DebuggerClient implementation. 86 // V8DebuggerClient implementation.
86 void runMessageLoopOnPause(int contextGroupId) override; 87 void runMessageLoopOnPause(int contextGroupId) override;
87 void quitMessageLoopOnPause() override; 88 void quitMessageLoopOnPause() override;
88 void muteWarningsAndDeprecations(int contextGroupId) override; 89 void muteWarningsAndDeprecations(int contextGroupId) override;
(...skipping 11 matching lines...) Expand all
100 101
101 static void querySelectorCallback(const v8::FunctionCallbackInfo<v8::Value>& ); 102 static void querySelectorCallback(const v8::FunctionCallbackInfo<v8::Value>& );
102 static void querySelectorAllCallback(const v8::FunctionCallbackInfo<v8::Valu e>&); 103 static void querySelectorAllCallback(const v8::FunctionCallbackInfo<v8::Valu e>&);
103 static void xpathSelectorCallback(const v8::FunctionCallbackInfo<v8::Value>& ); 104 static void xpathSelectorCallback(const v8::FunctionCallbackInfo<v8::Value>& );
104 }; 105 };
105 106
106 } // namespace blink 107 } // namespace blink
107 108
108 109
109 #endif // MainThreadDebugger_h 110 #endif // MainThreadDebugger_h
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698