OLD | NEW |
1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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 "base/logging.h" | 5 #include "base/logging.h" |
6 #include "base/process_util.h" | 6 #include "base/process_util.h" |
7 #include "base/shared_memory.h" | 7 #include "base/shared_memory.h" |
8 #include "base/task.h" | 8 #include "base/task.h" |
9 #include "chrome/common/gpu_messages.h" | 9 #include "chrome/common/gpu_messages.h" |
10 #include "chrome/common/plugin_messages.h" | 10 #include "chrome/common/plugin_messages.h" |
11 #include "chrome/renderer/command_buffer_proxy.h" | 11 #include "chrome/renderer/command_buffer_proxy.h" |
12 #include "chrome/renderer/plugin_channel_host.h" | 12 #include "chrome/renderer/plugin_channel_host.h" |
13 #include "gfx/size.h" | |
14 #include "gpu/command_buffer/common/cmd_buffer_common.h" | 13 #include "gpu/command_buffer/common/cmd_buffer_common.h" |
| 14 #include "ui/gfx/size.h" |
15 | 15 |
16 using gpu::Buffer; | 16 using gpu::Buffer; |
17 | 17 |
18 CommandBufferProxy::CommandBufferProxy( | 18 CommandBufferProxy::CommandBufferProxy( |
19 IPC::Channel::Sender* channel, | 19 IPC::Channel::Sender* channel, |
20 int route_id) | 20 int route_id) |
21 : num_entries_(0), | 21 : num_entries_(0), |
22 channel_(channel), | 22 channel_(channel), |
23 route_id_(route_id) { | 23 route_id_(route_id) { |
24 } | 24 } |
(...skipping 288 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
313 pending_async_flush_tasks_.pop(); | 313 pending_async_flush_tasks_.pop(); |
314 | 314 |
315 if (task.get()) { | 315 if (task.get()) { |
316 // Although we need need to update last_state_ while potentially waiting | 316 // Although we need need to update last_state_ while potentially waiting |
317 // for a synchronous flush to complete, we do not need to invoke the | 317 // for a synchronous flush to complete, we do not need to invoke the |
318 // callback synchonously. Also, post it as a non nestable task so it is | 318 // callback synchonously. Also, post it as a non nestable task so it is |
319 // always invoked by the outermost message loop. | 319 // always invoked by the outermost message loop. |
320 MessageLoop::current()->PostNonNestableTask(FROM_HERE, task.release()); | 320 MessageLoop::current()->PostNonNestableTask(FROM_HERE, task.release()); |
321 } | 321 } |
322 } | 322 } |
OLD | NEW |