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

Unified Diff: components/dom_distiller/ios/distiller_page_ios.mm

Issue 2539363004: Make base::Value::TYPE a scoped enum. (Closed)
Patch Set: Rebase Created 4 years 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 | « components/dom_distiller/core/distiller_page.cc ('k') | components/drive/service/fake_drive_service.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: components/dom_distiller/ios/distiller_page_ios.mm
diff --git a/components/dom_distiller/ios/distiller_page_ios.mm b/components/dom_distiller/ios/distiller_page_ios.mm
index a59548ae016bd82f1a14ebf921b252233d3ddbd1..8ae4962c07eb3141a760777cf400f6621656aafd 100644
--- a/components/dom_distiller/ios/distiller_page_ios.mm
+++ b/components/dom_distiller/ios/distiller_page_ios.mm
@@ -46,24 +46,24 @@ std::unique_ptr<base::Value> ValueResultFromScriptResult(id wk_result,
CFTypeID result_type = CFGetTypeID(wk_result);
if (result_type == CFStringGetTypeID()) {
result.reset(new base::StringValue(base::SysNSStringToUTF16(wk_result)));
- DCHECK(result->IsType(base::Value::TYPE_STRING));
+ DCHECK(result->IsType(base::Value::Type::STRING));
} else if (result_type == CFNumberGetTypeID()) {
// Different implementation is here.
if ([wk_result intValue] != [wk_result doubleValue]) {
result.reset(new base::FundamentalValue([wk_result doubleValue]));
- DCHECK(result->IsType(base::Value::TYPE_DOUBLE));
+ DCHECK(result->IsType(base::Value::Type::DOUBLE));
} else {
result.reset(new base::FundamentalValue([wk_result intValue]));
- DCHECK(result->IsType(base::Value::TYPE_INTEGER));
+ DCHECK(result->IsType(base::Value::Type::INTEGER));
}
// End of different implementation.
} else if (result_type == CFBooleanGetTypeID()) {
result.reset(
new base::FundamentalValue(static_cast<bool>([wk_result boolValue])));
- DCHECK(result->IsType(base::Value::TYPE_BOOLEAN));
+ DCHECK(result->IsType(base::Value::Type::BOOLEAN));
} else if (result_type == CFNullGetTypeID()) {
result = base::Value::CreateNullValue();
- DCHECK(result->IsType(base::Value::TYPE_NULL));
+ DCHECK(result->IsType(base::Value::Type::NONE));
} else if (result_type == CFDictionaryGetTypeID()) {
std::unique_ptr<base::DictionaryValue> dictionary =
base::MakeUnique<base::DictionaryValue>();
« no previous file with comments | « components/dom_distiller/core/distiller_page.cc ('k') | components/drive/service/fake_drive_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698