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 #ifndef WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_ | 5 #ifndef WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_ |
6 #define WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_ | 6 #define WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_ |
7 | 7 |
8 #include <string> | 8 #include <string> |
9 | 9 |
10 #include "base/callback_old.h" | 10 #include "base/callback_old.h" |
(...skipping 154 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
165 // of the callback. | 165 // of the callback. |
166 virtual void SetSwapBuffersCallback(Callback0::Type* callback) = 0; | 166 virtual void SetSwapBuffersCallback(Callback0::Type* callback) = 0; |
167 | 167 |
168 // If the plugin instance is backed by an OpenGL, return its ID in the | 168 // If the plugin instance is backed by an OpenGL, return its ID in the |
169 // compositors namespace. Otherwise return 0. Returns 0 by default. | 169 // compositors namespace. Otherwise return 0. Returns 0 by default. |
170 virtual unsigned GetBackingTextureId() = 0; | 170 virtual unsigned GetBackingTextureId() = 0; |
171 | 171 |
172 // This call will return the address of the command buffer for this context | 172 // This call will return the address of the command buffer for this context |
173 // that is constructed in Initialize() and is valid until this context is | 173 // that is constructed in Initialize() and is valid until this context is |
174 // destroyed. | 174 // destroyed. |
175 virtual gpu::CommandBuffer* GetCommandBuffer() = 0; | 175 virtual ::gpu::CommandBuffer* GetCommandBuffer() = 0; |
176 | 176 |
177 // Set an optional callback that will be invoked when the context is lost | 177 // Set an optional callback that will be invoked when the context is lost |
178 // (e.g. gpu process crash). Takes ownership of the callback. | 178 // (e.g. gpu process crash). Takes ownership of the callback. |
179 virtual void SetContextLostCallback(Callback0::Type* callback) = 0; | 179 virtual void SetContextLostCallback(Callback0::Type* callback) = 0; |
180 }; | 180 }; |
181 | 181 |
182 class PlatformAudio { | 182 class PlatformAudio { |
183 public: | 183 public: |
184 class Client { | 184 class Client { |
185 protected: | 185 protected: |
(...skipping 218 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
404 virtual base::SharedMemory* CreateAnonymousSharedMemory(uint32_t size) = 0; | 404 virtual base::SharedMemory* CreateAnonymousSharedMemory(uint32_t size) = 0; |
405 | 405 |
406 // Returns the current preferences. | 406 // Returns the current preferences. |
407 virtual ::ppapi::Preferences GetPreferences() = 0; | 407 virtual ::ppapi::Preferences GetPreferences() = 0; |
408 }; | 408 }; |
409 | 409 |
410 } // namespace ppapi | 410 } // namespace ppapi |
411 } // namespace webkit | 411 } // namespace webkit |
412 | 412 |
413 #endif // WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_ | 413 #endif // WEBKIT_PLUGINS_PPAPI_PLUGIN_DELEGATE_H_ |
OLD | NEW |