| 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 PPAPI_PROXY_PLUGIN_PROXY_DELEGATE_H_ | 5 #ifndef PPAPI_PROXY_PLUGIN_PROXY_DELEGATE_H_ |
| 6 #define PPAPI_PROXY_PLUGIN_PROXY_DELEGATE_H_ | 6 #define PPAPI_PROXY_PLUGIN_PROXY_DELEGATE_H_ |
| 7 | 7 |
| 8 namespace ppapi { | 8 namespace ppapi { |
| 9 namespace proxy { | 9 namespace proxy { |
| 10 | 10 |
| 11 class PPAPI_PROXY_EXPORT PluginProxyDelegate { | 11 class PPAPI_PROXY_EXPORT PluginProxyDelegate { |
| 12 public: | 12 public: |
| 13 virtual ~PluginProxyDelegate() {} | 13 virtual ~PluginProxyDelegate() {} |
| 14 | 14 |
| 15 // Returns the WebKit forwarding object used to make calls into WebKit. | |
| 16 // Necessary only on the plugin side. | |
| 17 virtual WebKitForwarding* GetWebKitForwarding() = 0; | |
| 18 | |
| 19 // Posts the given task to the WebKit thread associated with this plugin | |
| 20 // process. The WebKit thread should be lazily created if it does not | |
| 21 // exist yet. | |
| 22 virtual void PostToWebKitThread(const tracked_objects::Location& from_here, | |
| 23 const base::Closure& task) = 0; | |
| 24 | |
| 25 // Sends the given message to the browser. Identical semantics to | 15 // Sends the given message to the browser. Identical semantics to |
| 26 // IPC::Message::Sender interface. | 16 // IPC::Message::Sender interface. |
| 27 virtual bool SendToBrowser(IPC::Message* msg) = 0; | 17 virtual bool SendToBrowser(IPC::Message* msg) = 0; |
| 28 | 18 |
| 29 // Performs Windows-specific font caching in the browser for the given | 19 // Performs Windows-specific font caching in the browser for the given |
| 30 // LOGFONTW. Does nothing on non-Windows platforms. | 20 // LOGFONTW. Does nothing on non-Windows platforms. |
| 31 virtual void PreCacheFont(const void* logfontw) = 0; | 21 virtual void PreCacheFont(const void* logfontw) = 0; |
| 32 }; | 22 }; |
| 33 | 23 |
| 34 } // namespace proxy | 24 } // namespace proxy |
| 35 } // namespace ppapi | 25 } // namespace ppapi |
| 36 | 26 |
| 37 #endif // PPAPI_PROXY_PLUGIN_PROXY_DELEGATE_H_ | 27 #endif // PPAPI_PROXY_PLUGIN_PROXY_DELEGATE_H_ |
| OLD | NEW |