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

Unified Diff: Source/core/inspector/InspectorDOMDebuggerAgent.cpp

Issue 401523004: Break on window close when the inspector is open (Closed) Base URL: https://chromium.googlesource.com/chromium/blink.git@master
Patch Set: add window breakpoint category, add stacktrace to output Created 6 years, 5 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
Index: Source/core/inspector/InspectorDOMDebuggerAgent.cpp
diff --git a/Source/core/inspector/InspectorDOMDebuggerAgent.cpp b/Source/core/inspector/InspectorDOMDebuggerAgent.cpp
index f60ee761db34e18ac6b057eb080ba111cf2dd1fb..7f75e94babec32927f6f6a2837c9ebf08d927cd4 100644
--- a/Source/core/inspector/InspectorDOMDebuggerAgent.cpp
+++ b/Source/core/inspector/InspectorDOMDebuggerAgent.cpp
@@ -63,6 +63,7 @@ static const char animationFrameFiredEventName[] = "animationFrameFired";
static const char setTimerEventName[] = "setTimer";
static const char clearTimerEventName[] = "clearTimer";
static const char timerFiredEventName[] = "timerFired";
+static const char windowCloseEventName[] = "close";
static const char customElementCallbackName[] = "customElementCallback";
static const char webglErrorFiredEventName[] = "webglErrorFired";
static const char webglWarningFiredEventName[] = "webglWarningFired";
@@ -481,6 +482,11 @@ void InspectorDOMDebuggerAgent::willHandleEvent(EventTarget* target, Event* even
pauseOnNativeEventIfNeeded(preparePauseOnNativeEventData(event->type(), &targetName), false);
}
+void InspectorDOMDebuggerAgent::willCloseWindow()
+{
+ pauseOnNativeEventIfNeeded(preparePauseOnNativeEventData(windowCloseEventName, nullptr), true);
aandrey 2014/07/28 14:08:35 nullptr -> 0
+}
+
void InspectorDOMDebuggerAgent::willExecuteCustomElementCallback(Element*)
{
pauseOnNativeEventIfNeeded(preparePauseOnNativeEventData(customElementCallbackName, 0), false);

Powered by Google App Engine
This is Rietveld 408576698