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

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

Issue 2700123003: DO NOT COMMIT: Results of running old (current) clang-format on Blink (Closed)
Patch Set: Created 3 years, 10 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 /* 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 518 matching lines...) Expand 10 before | Expand all | Expand 10 after
529 // nodes where you can have an output with 0 channels. All other nodes have 529 // nodes where you can have an output with 0 channels. All other nodes have
530 // have at least one output channel, so there's no reason other nodes should 530 // have at least one output channel, so there's no reason other nodes should
531 // ever call this function. 531 // ever call this function.
532 DCHECK(0) << "numberOfOutputChannels() not valid for node type " 532 DCHECK(0) << "numberOfOutputChannels() not valid for node type "
533 << getNodeType(); 533 << getNodeType();
534 return 1; 534 return 1;
535 } 535 }
536 // ---------------------------------------------------------------- 536 // ----------------------------------------------------------------
537 537
538 AudioNode::AudioNode(BaseAudioContext& context) 538 AudioNode::AudioNode(BaseAudioContext& context)
539 : m_context(context), m_handler(nullptr) { 539 : m_context(context), m_handler(nullptr) {}
540 }
541 540
542 void AudioNode::dispose() { 541 void AudioNode::dispose() {
543 DCHECK(isMainThread()); 542 DCHECK(isMainThread());
544 #if DEBUG_AUDIONODE_REFERENCES 543 #if DEBUG_AUDIONODE_REFERENCES
545 fprintf(stderr, "[%16p]: %16p: %2d: AudioNode::dispose %16p\n", context(), 544 fprintf(stderr, "[%16p]: %16p: %2d: AudioNode::dispose %16p\n", context(),
546 this, handler().getNodeType(), m_handler.get()); 545 this, handler().getNodeType(), m_handler.get());
547 #endif 546 #endif
548 BaseAudioContext::AutoLocker locker(context()); 547 BaseAudioContext::AutoLocker locker(context());
549 handler().dispose(); 548 handler().dispose();
550 if (context()->contextState() == BaseAudioContext::Running) 549 if (context()->contextState() == BaseAudioContext::Running)
(...skipping 401 matching lines...) Expand 10 before | Expand all | Expand 10 after
952 } 951 }
953 952
954 void AudioNode::didAddOutput(unsigned numberOfOutputs) { 953 void AudioNode::didAddOutput(unsigned numberOfOutputs) {
955 m_connectedNodes.push_back(nullptr); 954 m_connectedNodes.push_back(nullptr);
956 DCHECK_EQ(numberOfOutputs, m_connectedNodes.size()); 955 DCHECK_EQ(numberOfOutputs, m_connectedNodes.size());
957 m_connectedParams.push_back(nullptr); 956 m_connectedParams.push_back(nullptr);
958 DCHECK_EQ(numberOfOutputs, m_connectedParams.size()); 957 DCHECK_EQ(numberOfOutputs, m_connectedParams.size());
959 } 958 }
960 959
961 } // namespace blink 960 } // namespace blink
OLDNEW
« no previous file with comments | « third_party/WebKit/Source/modules/webaudio/AudioNode.h ('k') | third_party/WebKit/Source/modules/webaudio/AudioNodeInput.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698