OLD | NEW |
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/proxy/ppb_testing_proxy.h" | 5 #include "ppapi/proxy/ppb_testing_proxy.h" |
6 | 6 |
7 #include "base/message_loop.h" | 7 #include "base/message_loop.h" |
8 #include "ppapi/c/dev/ppb_testing_dev.h" | 8 #include "ppapi/c/dev/ppb_testing_dev.h" |
9 #include "ppapi/proxy/plugin_dispatcher.h" | 9 #include "ppapi/proxy/plugin_dispatcher.h" |
10 #include "ppapi/proxy/plugin_resource_tracker.h" | 10 #include "ppapi/proxy/plugin_resource_tracker.h" |
11 #include "ppapi/proxy/ppapi_messages.h" | 11 #include "ppapi/proxy/ppapi_messages.h" |
12 #include "ppapi/shared_impl/resource.h" | 12 #include "ppapi/shared_impl/resource.h" |
13 | 13 |
14 using ppapi::HostResource; | 14 namespace ppapi { |
15 using ppapi::Resource; | |
16 | |
17 namespace pp { | |
18 namespace proxy { | 15 namespace proxy { |
19 | 16 |
20 namespace { | 17 namespace { |
21 | 18 |
22 PP_Bool ReadImageData(PP_Resource graphics_2d, | 19 PP_Bool ReadImageData(PP_Resource graphics_2d, |
23 PP_Resource image, | 20 PP_Resource image, |
24 const PP_Point* top_left) { | 21 const PP_Point* top_left) { |
25 Resource* image_object = PluginResourceTracker::GetInstance()-> | 22 Resource* image_object = PluginResourceTracker::GetInstance()-> |
26 GetResource(image); | 23 GetResource(image); |
27 if (!image_object) | 24 if (!image_object) |
(...skipping 100 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
128 void PPB_Testing_Proxy::OnMsgQuitMessageLoop(PP_Instance instance) { | 125 void PPB_Testing_Proxy::OnMsgQuitMessageLoop(PP_Instance instance) { |
129 ppb_testing_target()->QuitMessageLoop(instance); | 126 ppb_testing_target()->QuitMessageLoop(instance); |
130 } | 127 } |
131 | 128 |
132 void PPB_Testing_Proxy::OnMsgGetLiveObjectsForInstance(PP_Instance instance, | 129 void PPB_Testing_Proxy::OnMsgGetLiveObjectsForInstance(PP_Instance instance, |
133 uint32_t* result) { | 130 uint32_t* result) { |
134 *result = ppb_testing_target()->GetLiveObjectsForInstance(instance); | 131 *result = ppb_testing_target()->GetLiveObjectsForInstance(instance); |
135 } | 132 } |
136 | 133 |
137 } // namespace proxy | 134 } // namespace proxy |
138 } // namespace pp | 135 } // namespace ppapi |
OLD | NEW |