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

Side by Side Diff: ppapi/thunk/ppb_instance_thunk.cc

Issue 7874002: This patch tries to remove most of the manual registration for Pepper interfaces, and replaces it... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 9 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 | Annotate | Revision Log
« no previous file with comments | « ppapi/thunk/ppb_instance_api.h ('k') | ppapi/thunk/ppb_mouse_lock_thunk.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) 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 "ppapi/thunk/thunk.h" 5 #include "ppapi/thunk/thunk.h"
6 #include "ppapi/thunk/enter.h" 6 #include "ppapi/thunk/enter.h"
7 #include "ppapi/thunk/ppb_instance_api.h" 7 #include "ppapi/thunk/ppb_instance_api.h"
8 #include "ppapi/thunk/resource_creation_api.h" 8 #include "ppapi/thunk/resource_creation_api.h"
9 9
10 namespace ppapi { 10 namespace ppapi {
(...skipping 31 matching lines...) Expand 10 before | Expand all | Expand 10 after
42 42
43 PP_Var ExecuteScript(PP_Instance instance, 43 PP_Var ExecuteScript(PP_Instance instance,
44 PP_Var script, 44 PP_Var script,
45 PP_Var* exception) { 45 PP_Var* exception) {
46 EnterFunction<PPB_Instance_FunctionAPI> enter(instance, true); 46 EnterFunction<PPB_Instance_FunctionAPI> enter(instance, true);
47 if (enter.failed()) 47 if (enter.failed())
48 return PP_MakeUndefined(); 48 return PP_MakeUndefined();
49 return enter.functions()->ExecuteScript(instance, script, exception); 49 return enter.functions()->ExecuteScript(instance, script, exception);
50 } 50 }
51 51
52 const PPB_Instance_1_0 g_ppb_instance_1_0_thunk = { 52 const PPB_Instance g_ppb_instance_thunk = {
53 &BindGraphics, 53 &BindGraphics,
54 &IsFullFrame 54 &IsFullFrame
55 }; 55 };
56 56
57 const PPB_Instance_Private g_ppb_instance_private_thunk = { 57 const PPB_Instance_Private g_ppb_instance_private_thunk = {
58 &GetWindowObject, 58 &GetWindowObject,
59 &GetOwnerElementObject, 59 &GetOwnerElementObject,
60 &ExecuteScript 60 &ExecuteScript
61 }; 61 };
62 62
63 } // namespace 63 } // namespace
64 64
65 const PPB_Instance_1_0* GetPPB_Instance_1_0_Thunk() { 65 const PPB_Instance* GetPPB_Instance_Thunk() {
66 return &g_ppb_instance_1_0_thunk; 66 return &g_ppb_instance_thunk;
67 } 67 }
68 const PPB_Instance_Private* GetPPB_Instance_Private_Thunk() { 68 const PPB_Instance_Private* GetPPB_Instance_Private_Thunk() {
69 return &g_ppb_instance_private_thunk; 69 return &g_ppb_instance_private_thunk;
70 } 70 }
71 71
72 } // namespace thunk 72 } // namespace thunk
73 } // namespace ppapi 73 } // namespace ppapi
OLDNEW
« no previous file with comments | « ppapi/thunk/ppb_instance_api.h ('k') | ppapi/thunk/ppb_mouse_lock_thunk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698