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

Side by Side Diff: third_party/WebKit/Source/modules/webaudio/WindowAudioWorklet.cpp

Issue 2629593004: Disambiguate LifecycleObserver::contextDestroyed (Closed)
Patch Set: temp Created 3 years, 11 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 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "modules/webaudio/WindowAudioWorklet.h" 5 #include "modules/webaudio/WindowAudioWorklet.h"
6 6
7 #include "core/dom/Document.h" 7 #include "core/dom/Document.h"
8 #include "core/frame/LocalDOMWindow.h" 8 #include "core/frame/LocalDOMWindow.h"
9 #include "core/frame/LocalFrame.h" 9 #include "core/frame/LocalFrame.h"
10 #include "modules/webaudio/AudioWorklet.h" 10 #include "modules/webaudio/AudioWorklet.h"
(...skipping 33 matching lines...) Expand 10 before | Expand all | Expand 10 after
44 44
45 // Break the following cycle when the context gets detached. 45 // Break the following cycle when the context gets detached.
46 // Otherwise, the worklet object will leak. 46 // Otherwise, the worklet object will leak.
47 // 47 //
48 // window => window.audioWorklet 48 // window => window.audioWorklet
49 // => WindowAudioWorklet 49 // => WindowAudioWorklet
50 // => AudioWorklet <--- break this reference 50 // => AudioWorklet <--- break this reference
51 // => ThreadedWorkletMessagingProxy 51 // => ThreadedWorkletMessagingProxy
52 // => Document 52 // => Document
53 // => ... => window 53 // => ... => window
54 void WindowAudioWorklet::contextDestroyed() { 54 void WindowAudioWorklet::contextDestroyed(ExecutionContext*) {
55 m_audioWorklet = nullptr; 55 m_audioWorklet = nullptr;
56 } 56 }
57 57
58 DEFINE_TRACE(WindowAudioWorklet) { 58 DEFINE_TRACE(WindowAudioWorklet) {
59 visitor->trace(m_audioWorklet); 59 visitor->trace(m_audioWorklet);
60 Supplement<LocalDOMWindow>::trace(visitor); 60 Supplement<LocalDOMWindow>::trace(visitor);
61 ContextLifecycleObserver::trace(visitor); 61 ContextLifecycleObserver::trace(visitor);
62 } 62 }
63 63
64 } // namespace blink 64 } // namespace blink
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698