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

Side by Side Diff: gpu/command_buffer/service/shader_translator.cc

Issue 2414153005: Remove usage of FOR_EACH_OBSERVER macro in gpu (Closed)
Patch Set: Created 4 years, 2 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 | gpu/ipc/client/command_buffer_proxy_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "gpu/command_buffer/service/shader_translator.h" 5 #include "gpu/command_buffer/service/shader_translator.h"
6 6
7 #include <GLES2/gl2.h> 7 #include <GLES2/gl2.h>
8 #include <stddef.h> 8 #include <stddef.h>
9 #include <string.h> 9 #include <string.h>
10 #include <algorithm> 10 #include <algorithm>
(...skipping 258 matching lines...) Expand 10 before | Expand all | Expand 10 after
269 DestructionObserver* observer) { 269 DestructionObserver* observer) {
270 destruction_observers_.AddObserver(observer); 270 destruction_observers_.AddObserver(observer);
271 } 271 }
272 272
273 void ShaderTranslator::RemoveDestructionObserver( 273 void ShaderTranslator::RemoveDestructionObserver(
274 DestructionObserver* observer) { 274 DestructionObserver* observer) {
275 destruction_observers_.RemoveObserver(observer); 275 destruction_observers_.RemoveObserver(observer);
276 } 276 }
277 277
278 ShaderTranslator::~ShaderTranslator() { 278 ShaderTranslator::~ShaderTranslator() {
279 FOR_EACH_OBSERVER(DestructionObserver, 279 for (auto& observer : destruction_observers_)
280 destruction_observers_, 280 observer.OnDestruct(this);
281 OnDestruct(this));
282 281
283 if (compiler_ != NULL) 282 if (compiler_ != NULL)
284 ShDestruct(compiler_); 283 ShDestruct(compiler_);
285 } 284 }
286 285
287 } // namespace gles2 286 } // namespace gles2
288 } // namespace gpu 287 } // namespace gpu
289 288
OLDNEW
« no previous file with comments | « no previous file | gpu/ipc/client/command_buffer_proxy_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698