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

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

Issue 2008903002: Drop unique audio thread ID requirement. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
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 unified diff | Download patch
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/webaudio/AudioContext.cpp » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (C) 2010, Google Inc. All rights reserved. 2 * Copyright (C) 2010, Google Inc. All rights reserved.
3 * 3 *
4 * Redistribution and use in source and binary forms, with or without 4 * Redistribution and use in source and binary forms, with or without
5 * modification, are permitted provided that the following conditions 5 * modification, are permitted provided that the following conditions
6 * are met: 6 * are met:
7 * 1. Redistributions of source code must retain the above copyright 7 * 1. Redistributions of source code must retain the above copyright
8 * notice, this list of conditions and the following disclaimer. 8 * notice, this list of conditions and the following disclaimer.
9 * 2. Redistributions in binary form must reproduce the above copyright 9 * 2. Redistributions in binary form must reproduce the above copyright
10 * notice, this list of conditions and the following disclaimer in the 10 * notice, this list of conditions and the following disclaimer in the
(...skipping 132 matching lines...) Expand 10 before | Expand all | Expand 10 after
143 m_listener = AudioListener::create(*this); 143 m_listener = AudioListener::create(*this);
144 } 144 }
145 } 145 }
146 146
147 void AbstractAudioContext::clear() 147 void AbstractAudioContext::clear()
148 { 148 {
149 m_destinationNode.clear(); 149 m_destinationNode.clear();
150 // The audio rendering thread is dead. Nobody will schedule AudioHandler 150 // The audio rendering thread is dead. Nobody will schedule AudioHandler
151 // deletion. Let's do it ourselves. 151 // deletion. Let's do it ourselves.
152 deferredTaskHandler().clearHandlersToBeDeleted(); 152 deferredTaskHandler().clearHandlersToBeDeleted();
153 deferredTaskHandler().clearAudioThread();
154 m_isCleared = true; 153 m_isCleared = true;
155 } 154 }
156 155
157 void AbstractAudioContext::uninitialize() 156 void AbstractAudioContext::uninitialize()
158 { 157 {
159 ASSERT(isMainThread()); 158 ASSERT(isMainThread());
160 159
161 if (!isDestinationInitialized()) 160 if (!isDestinationInitialized())
162 return; 161 return;
163 162
(...skipping 818 matching lines...) Expand 10 before | Expand all | Expand 10 after
982 981
983 SecurityOrigin* AbstractAudioContext::getSecurityOrigin() const 982 SecurityOrigin* AbstractAudioContext::getSecurityOrigin() const
984 { 983 {
985 if (getExecutionContext()) 984 if (getExecutionContext())
986 return getExecutionContext()->getSecurityOrigin(); 985 return getExecutionContext()->getSecurityOrigin();
987 986
988 return nullptr; 987 return nullptr;
989 } 988 }
990 989
991 } // namespace blink 990 } // namespace blink
OLDNEW
« no previous file with comments | « no previous file | third_party/WebKit/Source/modules/webaudio/AudioContext.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698