summaryrefslogtreecommitdiffstats
path: root/chrome/renderer/command_buffer_proxy.cc
diff options
context:
space:
mode:
authorapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-20 01:20:47 +0000
committerapatrick@chromium.org <apatrick@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-20 01:20:47 +0000
commit024e9386c24b862cae3a4cf4bd22fd4651b02cc5 (patch)
tree12f9a2c80e2a142856c1adefc3253f66a491f0bb /chrome/renderer/command_buffer_proxy.cc
parent9cf005d236d090fb18d8a5b6c6c630a94e893ef4 (diff)
downloadchromium_src-024e9386c24b862cae3a4cf4bd22fd4651b02cc5.zip
chromium_src-024e9386c24b862cae3a4cf4bd22fd4651b02cc5.tar.gz
chromium_src-024e9386c24b862cae3a4cf4bd22fd4651b02cc5.tar.bz2
Revert 39530 - GPU plugin forwards repaint events to Pepper plugin.
WM_PAINT results in a call to Pepper repaint callback. Implemented WM_ERASEBKGND to prevent flickering on repaint. Implemented PGL_NO_CONTEXT (copied from EGL spec). This is already reviewed by alokp but unfortunately got entangled with this CL. TEST=none BUG=none Review URL: http://codereview.chromium.org/571018 TBR=alokp@chromium.org Review URL: http://codereview.chromium.org/650100 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@39535 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/renderer/command_buffer_proxy.cc')
-rw-r--r--chrome/renderer/command_buffer_proxy.cc19
1 files changed, 10 insertions, 9 deletions
diff --git a/chrome/renderer/command_buffer_proxy.cc b/chrome/renderer/command_buffer_proxy.cc
index b2eaa86..2b71fa8 100644
--- a/chrome/renderer/command_buffer_proxy.cc
+++ b/chrome/renderer/command_buffer_proxy.cc
@@ -37,8 +37,6 @@ CommandBufferProxy::~CommandBufferProxy() {
void CommandBufferProxy::OnMessageReceived(const IPC::Message& message) {
IPC_BEGIN_MESSAGE_MAP(CommandBufferProxy, message)
IPC_MESSAGE_HANDLER(CommandBufferMsg_UpdateState, OnUpdateState);
- IPC_MESSAGE_HANDLER(CommandBufferMsg_NotifyRepaint,
- OnNotifyRepaint);
IPC_MESSAGE_UNHANDLED_ERROR()
IPC_END_MESSAGE_MAP()
}
@@ -144,7 +142,16 @@ Buffer CommandBufferProxy::GetTransferBuffer(int32 id) {
}
// Cache the transfer buffer shared memory object client side.
- base::SharedMemory* shared_memory = new base::SharedMemory(handle, false);
+#if defined(OS_WIN)
+ // TODO(piman): Does Windows needs this version of the constructor ? It
+ // duplicates the handle, but I'm not sure why it is necessary - it was
+ // already duped by the CommandBufferStub.
+ base::SharedMemory* shared_memory =
+ new base::SharedMemory(handle, false, base::GetCurrentProcessHandle());
+#else
+ base::SharedMemory* shared_memory =
+ new base::SharedMemory(handle, false);
+#endif
// Map the shared memory on demand.
if (!shared_memory->memory()) {
@@ -168,12 +175,6 @@ void CommandBufferProxy::SetToken(int32 token) {
NOTREACHED();
}
-void CommandBufferProxy::OnNotifyRepaint() {
- if (notify_repaint_task_.get())
- MessageLoop::current()->PostNonNestableTask(
- FROM_HERE, notify_repaint_task_.release());
-}
-
void CommandBufferProxy::SetParseError(
gpu::error::Error error) {
// Not implemented in proxy.