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

Unified Diff: third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp

Issue 2105853002: Merge to 2743 "[DevTools] Explicitly reset context group when clearing ScriptController." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2743
Patch Set: Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « third_party/WebKit/Source/core/inspector/MainThreadDebugger.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp
diff --git a/third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp b/third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp
index 581fcb870b425f1dfa8e7b820a20221af99ff56a..14a1f2f585dd5b8059bd475e24df2afec37ff7c7 100644
--- a/third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp
+++ b/third_party/WebKit/Source/core/inspector/MainThreadDebugger.cpp
@@ -97,13 +97,18 @@ void MainThreadDebugger::setClientMessageLoop(PassOwnPtr<ClientMessageLoop> clie
m_clientMessageLoop = std::move(clientMessageLoop);
}
+void MainThreadDebugger::didClearContextsForFrame(LocalFrame* frame)
+{
+ DCHECK(isMainThread());
+ if (frame->localFrameRoot() == frame)
+ debugger()->resetContextGroup(contextGroupId(frame));
+}
+
void MainThreadDebugger::contextCreated(ScriptState* scriptState, LocalFrame* frame, SecurityOrigin* origin)
{
ASSERT(isMainThread());
v8::HandleScope handles(scriptState->isolate());
DOMWrapperWorld& world = scriptState->world();
- if (frame->localFrameRoot() == frame && world.isMainWorld())
- debugger()->resetContextGroup(contextGroupId(frame));
debugger()->contextCreated(V8ContextInfo(scriptState->context(), contextGroupId(frame), world.isMainWorld(), origin ? origin->toRawString() : "", world.isIsolatedWorld() ? world.isolatedWorldHumanReadableName() : "", IdentifiersFactory::frameId(frame), scriptState->getExecutionContext()->isDocument()));
}
« no previous file with comments | « third_party/WebKit/Source/core/inspector/MainThreadDebugger.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698