Chromium Code Reviews
DescriptionDevTools: properly handle target suspension/resuming in NetworkProject
NetworkProject adds UISourceCode in response to DebuggerModel.scriptParsed
event and removes UISourceCode in response to RuntimeModel.executionContextDestroyed.
In case of target suspension, the runtimeModel is not getting suspended and
does not destroy execution contexts. But DebuggerModel does get suspended and
later gets resumed, which results in duplicate scriptParsed events.
This patch starts listening to globalObjectCleared event in NetworkProject
to clean up scripts on target suspension.
Drive-by: promisify targetManager.suspendAllTargets(), make methods to
enable/disable debugger private.
R=dgozman
BUG=670180
Review-Url: https://codereview.chromium.org/2832943002
Cr-Commit-Position: refs/heads/master@{#469791}
Committed: https://chromium.googlesource.com/chromium/src/+/50d089bc61f3dd1546a1a6f6267f097db24fb541
Patch Set 1 #Patch Set 2 : fix tests #Patch Set 3 : nit #Patch Set 4 : listen to globalObjectCleared #Patch Set 5 : add tests #
Total comments: 6
Patch Set 6 : address comments #Dependent Patchsets: Messages
Total messages: 30 (23 generated)
|