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

Side by Side Diff: ppapi/proxy/raw_var_data.cc

Issue 18599005: [PPAPI] Added PP_VARTYPE_RESOURCE as a PP_VarType enum value. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix unittest_utils comparison of resource vars. Created 7 years, 3 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
OLDNEW
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2013 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 "ppapi/proxy/raw_var_data.h" 5 #include "ppapi/proxy/raw_var_data.h"
6 6
7 #include <stack> 7 #include <stack>
8 8
9 #include "base/containers/hash_tables.h" 9 #include "base/containers/hash_tables.h"
10 #include "base/stl_util.h" 10 #include "base/stl_util.h"
(...skipping 222 matching lines...) Expand 10 before | Expand all | Expand 10 after
233 case PP_VARTYPE_OBJECT: 233 case PP_VARTYPE_OBJECT:
234 return new BasicRawVarData(); 234 return new BasicRawVarData();
235 case PP_VARTYPE_STRING: 235 case PP_VARTYPE_STRING:
236 return new StringRawVarData(); 236 return new StringRawVarData();
237 case PP_VARTYPE_ARRAY_BUFFER: 237 case PP_VARTYPE_ARRAY_BUFFER:
238 return new ArrayBufferRawVarData(); 238 return new ArrayBufferRawVarData();
239 case PP_VARTYPE_ARRAY: 239 case PP_VARTYPE_ARRAY:
240 return new ArrayRawVarData(); 240 return new ArrayRawVarData();
241 case PP_VARTYPE_DICTIONARY: 241 case PP_VARTYPE_DICTIONARY:
242 return new DictionaryRawVarData(); 242 return new DictionaryRawVarData();
243 case PP_VARTYPE_RESOURCE:
244 // TODO(mgiuca): Add ResourceRawVarData. (http://crbug.com/177017)
245 // This path will be reached if a NaCl module attempts to pass a
246 // PP_VARTYPE_RESOURCE in a message.
247 NOTIMPLEMENTED();
248 CHECK(false) << "Serializing PP_VARTYPE_RESOURCE is not supported.";
raymes 2013/09/11 22:52:29 I realise that you are going to be changing this s
Matt Giuca 2013/09/12 07:08:24 OK, fair enough. That will result in a NULL point
249 return NULL;
243 } 250 }
244 NOTREACHED(); 251 NOTREACHED();
245 return NULL; 252 return NULL;
246 } 253 }
247 254
248 RawVarData::RawVarData() : initialized_(false) { 255 RawVarData::RawVarData() : initialized_(false) {
249 } 256 }
250 257
251 RawVarData::~RawVarData() { 258 RawVarData::~RawVarData() {
252 } 259 }
(...skipping 403 matching lines...) Expand 10 before | Expand all | Expand 10 after
656 return false; 663 return false;
657 if (!m->ReadUInt32(iter, &value)) 664 if (!m->ReadUInt32(iter, &value))
658 return false; 665 return false;
659 children_.push_back(make_pair(key, value)); 666 children_.push_back(make_pair(key, value));
660 } 667 }
661 return true; 668 return true;
662 } 669 }
663 670
664 } // namespace proxy 671 } // namespace proxy
665 } // namespace ppapi 672 } // namespace ppapi
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698