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

Side by Side Diff: webkit/glue/plugins/pepper_plugin_module.cc

Issue 2925007: Update Chrome to pull latest PPAPI with new uses of point and size.... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: '' Created 10 years, 5 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 | « webkit/glue/plugins/pepper_image_data.cc ('k') | webkit/glue/plugins/pepper_url_loader.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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/glue/plugins/pepper_plugin_module.h" 5 #include "webkit/glue/plugins/pepper_plugin_module.h"
6 6
7 #include <set> 7 #include <set>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/message_loop.h" 10 #include "base/message_loop.h"
(...skipping 103 matching lines...) Expand 10 before | Expand all | Expand 10 after
114 &MemAlloc, 114 &MemAlloc,
115 &MemFree, 115 &MemFree,
116 &GetTime, 116 &GetTime,
117 &CallOnMainThread 117 &CallOnMainThread
118 }; 118 };
119 119
120 // PPB_Testing ----------------------------------------------------------------- 120 // PPB_Testing -----------------------------------------------------------------
121 121
122 bool ReadImageData(PP_Resource device_context_2d, 122 bool ReadImageData(PP_Resource device_context_2d,
123 PP_Resource image, 123 PP_Resource image,
124 int32_t x, int32_t y) { 124 const PP_Point* top_left) {
125 scoped_refptr<DeviceContext2D> context( 125 scoped_refptr<DeviceContext2D> context(
126 Resource::GetAs<DeviceContext2D>(device_context_2d)); 126 Resource::GetAs<DeviceContext2D>(device_context_2d));
127 if (!context.get()) 127 if (!context.get())
128 return false; 128 return false;
129 return context->ReadImageData(image, x, y); 129 return context->ReadImageData(image, top_left);
130 } 130 }
131 131
132 void RunMessageLoop() { 132 void RunMessageLoop() {
133 bool old_state = MessageLoop::current()->NestableTasksAllowed(); 133 bool old_state = MessageLoop::current()->NestableTasksAllowed();
134 MessageLoop::current()->SetNestableTasksAllowed(true); 134 MessageLoop::current()->SetNestableTasksAllowed(true);
135 MessageLoop::current()->Run(); 135 MessageLoop::current()->Run();
136 MessageLoop::current()->SetNestableTasksAllowed(old_state); 136 MessageLoop::current()->SetNestableTasksAllowed(old_state);
137 } 137 }
138 138
139 void QuitMessageLoop() { 139 void QuitMessageLoop() {
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
343 343
344 void PluginModule::InstanceCreated(PluginInstance* instance) { 344 void PluginModule::InstanceCreated(PluginInstance* instance) {
345 instances_.insert(instance); 345 instances_.insert(instance);
346 } 346 }
347 347
348 void PluginModule::InstanceDeleted(PluginInstance* instance) { 348 void PluginModule::InstanceDeleted(PluginInstance* instance) {
349 instances_.erase(instance); 349 instances_.erase(instance);
350 } 350 }
351 351
352 } // namespace pepper 352 } // namespace pepper
OLDNEW
« no previous file with comments | « webkit/glue/plugins/pepper_image_data.cc ('k') | webkit/glue/plugins/pepper_url_loader.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698