| OLD | NEW |
| 1 // Copyright 2013 The Chromium Authors. All rights reserved. | 1 // Copyright 2013 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 COMPONENTS_PLUGINS_RENDERER_WEBVIEW_PLUGIN_H_ | 5 #ifndef COMPONENTS_PLUGINS_RENDERER_WEBVIEW_PLUGIN_H_ |
| 6 #define COMPONENTS_PLUGINS_RENDERER_WEBVIEW_PLUGIN_H_ | 6 #define COMPONENTS_PLUGINS_RENDERER_WEBVIEW_PLUGIN_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 | 9 |
| 10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
| (...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 53 // Convenience method to set up a new WebViewPlugin using |preferences| | 53 // Convenience method to set up a new WebViewPlugin using |preferences| |
| 54 // and displaying |html_data|. |url| should be a (fake) data:text/html URL; | 54 // and displaying |html_data|. |url| should be a (fake) data:text/html URL; |
| 55 // it is only used for navigation and never actually resolved. | 55 // it is only used for navigation and never actually resolved. |
| 56 static WebViewPlugin* Create(Delegate* delegate, | 56 static WebViewPlugin* Create(Delegate* delegate, |
| 57 const content::WebPreferences& preferences, | 57 const content::WebPreferences& preferences, |
| 58 const std::string& html_data, | 58 const std::string& html_data, |
| 59 const GURL& url); | 59 const GURL& url); |
| 60 | 60 |
| 61 blink::WebView* web_view() { return web_view_; } | 61 blink::WebView* web_view() { return web_view_; } |
| 62 | 62 |
| 63 // When loading a plug-in document (i.e. a full page plug-in not embedded in | 63 // When loading a plugin document (i.e. a full page plugin not embedded in |
| 64 // another page), we save all data that has been received, and replay it with | 64 // another page), we save all data that has been received, and replay it with |
| 65 // this method on the actual plug-in. | 65 // this method on the actual plugin. |
| 66 void ReplayReceivedData(blink::WebPlugin* plugin); | 66 void ReplayReceivedData(blink::WebPlugin* plugin); |
| 67 | 67 |
| 68 void RestoreTitleText(); | 68 void RestoreTitleText(); |
| 69 | 69 |
| 70 // WebPlugin methods: | 70 // WebPlugin methods: |
| 71 virtual blink::WebPluginContainer* container() const; | 71 virtual blink::WebPluginContainer* container() const; |
| 72 virtual bool initialize(blink::WebPluginContainer*); | 72 virtual bool initialize(blink::WebPluginContainer*); |
| 73 virtual void destroy(); | 73 virtual void destroy(); |
| 74 | 74 |
| 75 virtual NPObject* scriptableObject(); | 75 virtual NPObject* scriptableObject(); |
| (...skipping 83 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 159 | 159 |
| 160 blink::WebURLResponse response_; | 160 blink::WebURLResponse response_; |
| 161 std::list<std::string> data_; | 161 std::list<std::string> data_; |
| 162 bool finished_loading_; | 162 bool finished_loading_; |
| 163 scoped_ptr<blink::WebURLError> error_; | 163 scoped_ptr<blink::WebURLError> error_; |
| 164 blink::WebString old_title_; | 164 blink::WebString old_title_; |
| 165 bool focused_; | 165 bool focused_; |
| 166 }; | 166 }; |
| 167 | 167 |
| 168 #endif // COMPONENTS_PLUGINS_RENDERER_WEBVIEW_PLUGIN_H_ | 168 #endif // COMPONENTS_PLUGINS_RENDERER_WEBVIEW_PLUGIN_H_ |
| OLD | NEW |