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

Side by Side Diff: src/ports/SkGlobalInitialization_chromium.cpp

Issue 806473006: namespace {} trick for SK_DECLARE_STATIC_ONCE (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: Created 5 years, 11 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 2011 Google Inc. 2 * Copyright 2011 Google Inc.
3 * 3 *
4 * Use of this source code is governed by a BSD-style license that can be 4 * Use of this source code is governed by a BSD-style license that can be
5 * found in the LICENSE file. 5 * found in the LICENSE file.
6 */ 6 */
7 7
8 #include "SkTypes.h" 8 #include "SkTypes.h"
9 9
10 #include "SkBitmapProcShader.h" 10 #include "SkBitmapProcShader.h"
(...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after
113 SkArithmeticMode::InitializeFlattenables(); 113 SkArithmeticMode::InitializeFlattenables();
114 SkBlurMaskFilter::InitializeFlattenables(); 114 SkBlurMaskFilter::InitializeFlattenables();
115 SkColorFilter::InitializeFlattenables(); 115 SkColorFilter::InitializeFlattenables();
116 SkGradientShader::InitializeFlattenables(); 116 SkGradientShader::InitializeFlattenables();
117 SkLightingImageFilter::InitializeFlattenables(); 117 SkLightingImageFilter::InitializeFlattenables();
118 SkTableColorFilter::InitializeFlattenables(); 118 SkTableColorFilter::InitializeFlattenables();
119 SkXfermode::InitializeFlattenables(); 119 SkXfermode::InitializeFlattenables();
120 } 120 }
121 }; 121 };
122 122
123 SK_DECLARE_STATIC_ONCE(once);
123 void SkFlattenable::InitializeFlattenablesIfNeeded() { 124 void SkFlattenable::InitializeFlattenablesIfNeeded() {
124 SK_DECLARE_STATIC_ONCE(once);
125 SkOnce(&once, SkPrivateEffectInitializer::Init); 125 SkOnce(&once, SkPrivateEffectInitializer::Init);
126 } 126 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698