| OLD | NEW |
| 1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "content/renderer/browser_plugin/mock_browser_plugin.h" | 5 #include "content/renderer/browser_plugin/mock_browser_plugin.h" |
| 6 #include "content/renderer/render_process_impl.h" | 6 #include "content/renderer/render_process_impl.h" |
| 7 | 7 |
| 8 namespace content { | 8 namespace content { |
| 9 | 9 |
| 10 MockBrowserPlugin::MockBrowserPlugin( | 10 MockBrowserPlugin::MockBrowserPlugin( |
| (...skipping 10 matching lines...) Expand all Loading... |
| 21 TransportDIB* MockBrowserPlugin::CreateTransportDIB(const size_t size) { | 21 TransportDIB* MockBrowserPlugin::CreateTransportDIB(const size_t size) { |
| 22 return TransportDIB::Create(size, transport_dib_next_sequence_number_++); | 22 return TransportDIB::Create(size, transport_dib_next_sequence_number_++); |
| 23 } | 23 } |
| 24 | 24 |
| 25 void MockBrowserPlugin::FreeDamageBuffer(TransportDIB** damage_buffer) { | 25 void MockBrowserPlugin::FreeDamageBuffer(TransportDIB** damage_buffer) { |
| 26 DCHECK(*damage_buffer); | 26 DCHECK(*damage_buffer); |
| 27 RenderProcess::current()->FreeTransportDIB(*damage_buffer); | 27 RenderProcess::current()->FreeTransportDIB(*damage_buffer); |
| 28 *damage_buffer = NULL; | 28 *damage_buffer = NULL; |
| 29 } | 29 } |
| 30 | 30 |
| 31 bool MockBrowserPlugin::ReceiveMessage(IPC::Message* message) { |
| 32 bool handled = OnMessageReceived(*message); |
| 33 delete message; |
| 34 return handled; |
| 35 } |
| 36 |
| 31 } // namespace content | 37 } // namespace content |
| OLD | NEW |