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

Side by Side Diff: ipc/ipc_message_utils.cc

Issue 2476493003: Remove FundamentalValue
Patch Set: Fix Created 4 years, 1 month 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 | « ipc/ipc_message_unittest.cc ('k') | ipc/ipc_message_utils_unittest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "ipc/ipc_message_utils.h" 5 #include "ipc/ipc_message_utils.h"
6 6
7 #include <stddef.h> 7 #include <stddef.h>
8 #include <stdint.h> 8 #include <stdint.h>
9 9
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 254 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 return false; 265 return false;
266 266
267 switch (type) { 267 switch (type) {
268 case base::Value::TYPE_NULL: 268 case base::Value::TYPE_NULL:
269 *value = base::Value::CreateNullValue().release(); 269 *value = base::Value::CreateNullValue().release();
270 break; 270 break;
271 case base::Value::TYPE_BOOLEAN: { 271 case base::Value::TYPE_BOOLEAN: {
272 bool val; 272 bool val;
273 if (!ReadParam(m, iter, &val)) 273 if (!ReadParam(m, iter, &val))
274 return false; 274 return false;
275 *value = new base::FundamentalValue(val); 275 *value = new base::Value(val);
276 break; 276 break;
277 } 277 }
278 case base::Value::TYPE_INTEGER: { 278 case base::Value::TYPE_INTEGER: {
279 int val; 279 int val;
280 if (!ReadParam(m, iter, &val)) 280 if (!ReadParam(m, iter, &val))
281 return false; 281 return false;
282 *value = new base::FundamentalValue(val); 282 *value = new base::Value(val);
283 break; 283 break;
284 } 284 }
285 case base::Value::TYPE_DOUBLE: { 285 case base::Value::TYPE_DOUBLE: {
286 double val; 286 double val;
287 if (!ReadParam(m, iter, &val)) 287 if (!ReadParam(m, iter, &val))
288 return false; 288 return false;
289 *value = new base::FundamentalValue(val); 289 *value = new base::Value(val);
290 break; 290 break;
291 } 291 }
292 case base::Value::TYPE_STRING: { 292 case base::Value::TYPE_STRING: {
293 std::string val; 293 std::string val;
294 if (!ReadParam(m, iter, &val)) 294 if (!ReadParam(m, iter, &val))
295 return false; 295 return false;
296 *value = new base::StringValue(val); 296 *value = new base::StringValue(val);
297 break; 297 break;
298 } 298 }
299 case base::Value::TYPE_BINARY: { 299 case base::Value::TYPE_BINARY: {
(...skipping 925 matching lines...) Expand 10 before | Expand all | Expand 10 after
1225 return result; 1225 return result;
1226 } 1226 }
1227 1227
1228 void ParamTraits<MSG>::Log(const param_type& p, std::string* l) { 1228 void ParamTraits<MSG>::Log(const param_type& p, std::string* l) {
1229 l->append("<MSG>"); 1229 l->append("<MSG>");
1230 } 1230 }
1231 1231
1232 #endif // OS_WIN 1232 #endif // OS_WIN
1233 1233
1234 } // namespace IPC 1234 } // namespace IPC
OLDNEW
« no previous file with comments | « ipc/ipc_message_unittest.cc ('k') | ipc/ipc_message_utils_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698