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

Unified Diff: include/core/SkWriter32.h

Issue 158953003: Reland SkWriter32 growth change with build fixes. (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: small things Created 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « include/core/SkTDArray.h ('k') | src/core/SkWriter32.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: include/core/SkWriter32.h
diff --git a/include/core/SkWriter32.h b/include/core/SkWriter32.h
index df1275f7b656829ad132f7b481508e42b53d99e7..7d8d764e5944123a0819204dd0863f6a1b84bacb 100644
--- a/include/core/SkWriter32.h
+++ b/include/core/SkWriter32.h
@@ -67,7 +67,7 @@ public:
size_t offset = fUsed;
size_t totalRequired = fUsed + size;
if (totalRequired > fCapacity) {
- growToAtLeast(totalRequired);
+ this->growToAtLeast(totalRequired);
}
fUsed = totalRequired;
return (uint32_t*)(fData + offset);
@@ -247,7 +247,9 @@ private:
*/
template <size_t SIZE> class SkSWriter32 : public SkWriter32 {
public:
- SkSWriter32() : SkWriter32(fData.fStorage, SIZE) {}
+ SkSWriter32() { this->reset(); }
+
+ void reset() {this->INHERITED::reset(fData.fStorage, SIZE); }
private:
union {
@@ -255,6 +257,8 @@ private:
double fDoubleAlignment;
char fStorage[SIZE];
} fData;
+
+ typedef SkWriter32 INHERITED;
};
#endif
« no previous file with comments | « include/core/SkTDArray.h ('k') | src/core/SkWriter32.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698