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

Side by Side Diff: src/effects/gradients/SkGradientBitmapCache.h

Issue 1809733002: detach -> release (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: (C) Created 4 years, 9 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 | « src/effects/SkBlurMask.cpp ('k') | src/effects/gradients/SkGradientBitmapCache.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 /* 2 /*
3 * Copyright 2010 Google Inc. 3 * Copyright 2010 Google Inc.
4 * 4 *
5 * Use of this source code is governed by a BSD-style license that can be 5 * Use of this source code is governed by a BSD-style license that can be
6 * found in the LICENSE file. 6 * found in the LICENSE file.
7 */ 7 */
8 8
9 9
10 #ifndef SkGradientBitmapCache_DEFINED 10 #ifndef SkGradientBitmapCache_DEFINED
(...skipping 10 matching lines...) Expand all
21 void add(const void* buffer, size_t len, const SkBitmap&); 21 void add(const void* buffer, size_t len, const SkBitmap&);
22 22
23 private: 23 private:
24 int fEntryCount; 24 int fEntryCount;
25 const int fMaxEntries; 25 const int fMaxEntries;
26 26
27 struct Entry; 27 struct Entry;
28 mutable Entry* fHead; 28 mutable Entry* fHead;
29 mutable Entry* fTail; 29 mutable Entry* fTail;
30 30
31 inline Entry* detach(Entry*) const; 31 inline Entry* release(Entry*) const;
32 inline void attachToHead(Entry*) const; 32 inline void attachToHead(Entry*) const;
33 33
34 #ifdef SK_DEBUG 34 #ifdef SK_DEBUG
35 void validate() const; 35 void validate() const;
36 #else 36 #else
37 void validate() const {} 37 void validate() const {}
38 #endif 38 #endif
39 39
40 class AutoValidate : SkNoncopyable { 40 class AutoValidate : SkNoncopyable {
41 public: 41 public:
42 AutoValidate(const SkGradientBitmapCache* bc) : fBC(bc) { bc->validate() ; } 42 AutoValidate(const SkGradientBitmapCache* bc) : fBC(bc) { bc->validate() ; }
43 ~AutoValidate() { fBC->validate(); } 43 ~AutoValidate() { fBC->validate(); }
44 private: 44 private:
45 const SkGradientBitmapCache* fBC; 45 const SkGradientBitmapCache* fBC;
46 }; 46 };
47 }; 47 };
48 48
49 #endif 49 #endif
OLDNEW
« no previous file with comments | « src/effects/SkBlurMask.cpp ('k') | src/effects/gradients/SkGradientBitmapCache.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698