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_WEBVIEW_PLUGIN_H_ | 5 #ifndef WEBKIT_PLUGINS_WEBVIEW_PLUGIN_H_ |
6 #define WEBKIT_PLUGINS_WEBVIEW_PLUGIN_H_ | 6 #define WEBKIT_PLUGINS_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" |
11 #include "base/message_loop_helpers.h" | 11 #include "base/task.h" |
12 #include "third_party/WebKit/Source/WebKit/chromium/public/WebCursorInfo.h" | 12 #include "third_party/WebKit/Source/WebKit/chromium/public/WebCursorInfo.h" |
13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrameClient.h" | 13 #include "third_party/WebKit/Source/WebKit/chromium/public/WebFrameClient.h" |
14 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPlugin.h" | 14 #include "third_party/WebKit/Source/WebKit/chromium/public/WebPlugin.h" |
15 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h" | 15 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebString.h" |
16 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLRespon
se.h" | 16 #include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURLRespon
se.h" |
17 #include "third_party/WebKit/Source/WebKit/chromium/public/WebViewClient.h" | 17 #include "third_party/WebKit/Source/WebKit/chromium/public/WebViewClient.h" |
18 #include "webkit/plugins/webkit_plugins_export.h" | 18 #include "webkit/plugins/webkit_plugins_export.h" |
19 | 19 |
20 namespace WebKit { | 20 namespace WebKit { |
21 class WebMouseEvent; | 21 class WebMouseEvent; |
(...skipping 113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
135 | 135 |
136 // This method is defined in WebPlugin as well as in WebFrameClient, but with | 136 // This method is defined in WebPlugin as well as in WebFrameClient, but with |
137 // different parameters. We only care about implementing the WebPlugin | 137 // different parameters. We only care about implementing the WebPlugin |
138 // version, so we implement this method and call the default in WebFrameClient | 138 // version, so we implement this method and call the default in WebFrameClient |
139 // (which does nothing) to correctly overload it. | 139 // (which does nothing) to correctly overload it. |
140 virtual void didReceiveResponse(WebKit::WebFrame* frame, | 140 virtual void didReceiveResponse(WebKit::WebFrame* frame, |
141 unsigned identifier, | 141 unsigned identifier, |
142 const WebKit::WebURLResponse& response); | 142 const WebKit::WebURLResponse& response); |
143 | 143 |
144 private: | 144 private: |
145 friend class base::DeleteHelper<WebViewPlugin>; | 145 friend class DeleteTask<WebViewPlugin>; |
146 virtual ~WebViewPlugin(); | 146 virtual ~WebViewPlugin(); |
147 | 147 |
148 Delegate* delegate_; | 148 Delegate* delegate_; |
149 // Destroys itself. | 149 // Destroys itself. |
150 WebKit::WebCursorInfo current_cursor_; | 150 WebKit::WebCursorInfo current_cursor_; |
151 // Owns us. | 151 // Owns us. |
152 WebKit::WebPluginContainer* container_; | 152 WebKit::WebPluginContainer* container_; |
153 // Owned by us, deleted via |close()|. | 153 // Owned by us, deleted via |close()|. |
154 WebKit::WebView* web_view_; | 154 WebKit::WebView* web_view_; |
155 gfx::Rect rect_; | 155 gfx::Rect rect_; |
156 | 156 |
157 WebKit::WebURLResponse response_; | 157 WebKit::WebURLResponse response_; |
158 std::list<std::string> data_; | 158 std::list<std::string> data_; |
159 bool finished_loading_; | 159 bool finished_loading_; |
160 scoped_ptr<WebKit::WebURLError> error_; | 160 scoped_ptr<WebKit::WebURLError> error_; |
161 WebKit::WebString old_title_; | 161 WebKit::WebString old_title_; |
162 }; | 162 }; |
163 | 163 |
164 } // namespace webkit | 164 } // namespace webkit |
165 | 165 |
166 #endif // WEBKIT_PLUGINS_WEBVIEW_PLUGIN_H_ | 166 #endif // WEBKIT_PLUGINS_WEBVIEW_PLUGIN_H_ |
OLD | NEW |