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

Side by Side Diff: webkit/plugins/ppapi/npapi_glue.cc

Issue 8502030: Draft of a PPAPI interface for ArrayBuffer and typed arrays. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge Created 9 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « webkit/plugins/ppapi/message_channel.cc ('k') | no next file » | 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "webkit/plugins/ppapi/npapi_glue.h" 5 #include "webkit/plugins/ppapi/npapi_glue.h"
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/string_util.h" 9 #include "base/string_util.h"
10 #include "webkit/plugins/ppapi/host_globals.h" 10 #include "webkit/plugins/ppapi/host_globals.h"
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after
68 if (!object) { 68 if (!object) {
69 VOID_TO_NPVARIANT(*result); 69 VOID_TO_NPVARIANT(*result);
70 return false; 70 return false;
71 } 71 }
72 OBJECT_TO_NPVARIANT(WebBindings::retainObject(object->np_object()), 72 OBJECT_TO_NPVARIANT(WebBindings::retainObject(object->np_object()),
73 *result); 73 *result);
74 break; 74 break;
75 } 75 }
76 case PP_VARTYPE_ARRAY: 76 case PP_VARTYPE_ARRAY:
77 case PP_VARTYPE_DICTIONARY: 77 case PP_VARTYPE_DICTIONARY:
78 case PP_VARTYPE_ARRAY_BUFFER:
78 VOID_TO_NPVARIANT(*result); 79 VOID_TO_NPVARIANT(*result);
79 break; 80 break;
80 } 81 }
81 return true; 82 return true;
82 } 83 }
83 84
84 PP_Var NPVariantToPPVar(PluginInstance* instance, const NPVariant* variant) { 85 PP_Var NPVariantToPPVar(PluginInstance* instance, const NPVariant* variant) {
85 switch (variant->type) { 86 switch (variant->type) {
86 case NPVariantType_Void: 87 case NPVariantType_Void:
87 return PP_MakeUndefined(); 88 return PP_MakeUndefined();
(...skipping 224 matching lines...) Expand 10 before | Expand all | Expand 10 after
312 } 313 }
313 } 314 }
314 315
315 // static 316 // static
316 void TryCatch::Catch(void* self, const char* message) { 317 void TryCatch::Catch(void* self, const char* message) {
317 static_cast<TryCatch*>(self)->SetException(message); 318 static_cast<TryCatch*>(self)->SetException(message);
318 } 319 }
319 320
320 } // namespace ppapi 321 } // namespace ppapi
321 } // namespace webkit 322 } // namespace webkit
OLDNEW
« no previous file with comments | « webkit/plugins/ppapi/message_channel.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698