| OLD | NEW |
| 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 204 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 215 { | 215 { |
| 216 disconnectAllInputs(); | 216 disconnectAllInputs(); |
| 217 disconnectAllParams(); | 217 disconnectAllParams(); |
| 218 } | 218 } |
| 219 | 219 |
| 220 void AudioNodeOutput::disable() | 220 void AudioNodeOutput::disable() |
| 221 { | 221 { |
| 222 ASSERT(context()->isGraphOwner()); | 222 ASSERT(context()->isGraphOwner()); |
| 223 | 223 |
| 224 if (m_isEnabled) { | 224 if (m_isEnabled) { |
| 225 m_isEnabled = false; |
| 225 for (InputsIterator i = m_inputs.begin(); i != m_inputs.end(); ++i) | 226 for (InputsIterator i = m_inputs.begin(); i != m_inputs.end(); ++i) |
| 226 i->key->disable(*this); | 227 i->key->disable(*this); |
| 227 m_isEnabled = false; | |
| 228 } | 228 } |
| 229 } | 229 } |
| 230 | 230 |
| 231 void AudioNodeOutput::enable() | 231 void AudioNodeOutput::enable() |
| 232 { | 232 { |
| 233 ASSERT(context()->isGraphOwner()); | 233 ASSERT(context()->isGraphOwner()); |
| 234 | 234 |
| 235 if (!m_isEnabled) { | 235 if (!m_isEnabled) { |
| 236 m_isEnabled = true; |
| 236 for (InputsIterator i = m_inputs.begin(); i != m_inputs.end(); ++i) | 237 for (InputsIterator i = m_inputs.begin(); i != m_inputs.end(); ++i) |
| 237 i->key->enable(*this); | 238 i->key->enable(*this); |
| 238 m_isEnabled = true; | |
| 239 } | 239 } |
| 240 } | 240 } |
| 241 | 241 |
| 242 } // namespace blink | 242 } // namespace blink |
| 243 | 243 |
| 244 #endif // ENABLE(WEB_AUDIO) | 244 #endif // ENABLE(WEB_AUDIO) |
| OLD | NEW |