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

Unified Diff: Source/modules/webaudio/AudioNodeInput.cpp

Issue 349213007: WebAudio: Remove AudioNode::RefType. (Closed) Base URL: svn://svn.chromium.org/blink/trunk
Patch Set: Created 6 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
Index: Source/modules/webaudio/AudioNodeInput.cpp
diff --git a/Source/modules/webaudio/AudioNodeInput.cpp b/Source/modules/webaudio/AudioNodeInput.cpp
index 24da41ddfa1bf27a64ca4084eccee688179eb1ab..a2e0e2cad3b6fe53f2d15c983bb1e78ed57418e3 100644
--- a/Source/modules/webaudio/AudioNodeInput.cpp
+++ b/Source/modules/webaudio/AudioNodeInput.cpp
@@ -64,9 +64,6 @@ void AudioNodeInput::connect(AudioNodeOutput* output)
output->addInput(this);
m_outputs.add(output);
changedOutputs();
-
- // Sombody has just connected to us, so count it as a reference.
- node()->ref(AudioNode::RefTypeConnection);
}
void AudioNodeInput::disconnect(AudioNodeOutput* output)
@@ -82,7 +79,8 @@ void AudioNodeInput::disconnect(AudioNodeOutput* output)
m_outputs.remove(output);
changedOutputs();
output->removeInput(this);
- node()->deref(AudioNode::RefTypeConnection); // Note: it's important to return immediately after all deref() calls since the node may be deleted.
+ // Note: it's important to return immediately after removeInput() calls
+ // since the node may be deleted.
return;
}
@@ -90,7 +88,8 @@ void AudioNodeInput::disconnect(AudioNodeOutput* output)
if (m_disabledOutputs.contains(output)) {
m_disabledOutputs.remove(output);
output->removeInput(this);
- node()->deref(AudioNode::RefTypeConnection); // Note: it's important to return immediately after all deref() calls since the node may be deleted.
+ // Note: it's important to return immediately after all removeInput() calls
+ // since the node may be deleted.
return;
}

Powered by Google App Engine
This is Rietveld 408576698