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

Unified Diff: src/core/SkValidatingReadBuffer.cpp

Issue 1834303003: Delete SkFlattenable::Type (Closed) Base URL: https://skia.googlesource.com/skia.git@master
Patch Set: 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « src/core/SkValidatingReadBuffer.h ('k') | src/utils/SkBitmapSourceDeserializer.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/core/SkValidatingReadBuffer.cpp
diff --git a/src/core/SkValidatingReadBuffer.cpp b/src/core/SkValidatingReadBuffer.cpp
index bc5611a3e382902878ca99256f6d26ff0e80c3c2..402ddef229ae447e56cfa3834db5b1b4d7618d1c 100644
--- a/src/core/SkValidatingReadBuffer.cpp
+++ b/src/core/SkValidatingReadBuffer.cpp
@@ -222,20 +222,14 @@ bool SkValidatingReadBuffer::validateAvailable(size_t size) {
return this->validate((size <= SK_MaxU32) && fReader.isAvailable(static_cast<uint32_t>(size)));
}
-SkFlattenable* SkValidatingReadBuffer::readFlattenable(SkFlattenable::Type type) {
+SkFlattenable* SkValidatingReadBuffer::readFlattenable() {
SkString name;
this->readString(&name);
if (fError) {
return nullptr;
}
- // Is this the type we wanted ?
const char* cname = name.c_str();
- SkFlattenable::Type baseType;
- if (!SkFlattenable::NameToType(cname, &baseType) || (baseType != type)) {
mtklein 2016/04/01 14:20:42 Hmm. So there's the value. Let's sit on this unt
- return nullptr;
- }
-
SkFlattenable::Factory factory = SkFlattenable::NameToFactory(cname);
if (nullptr == factory) {
return nullptr; // writer failed to give us the flattenable
« no previous file with comments | « src/core/SkValidatingReadBuffer.h ('k') | src/utils/SkBitmapSourceDeserializer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698