Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(19)

Side by Side Diff: webkit/glue/webplugin_impl.h

Issue 165381: Merge 22369 - Fix plugin IPC issues.... (Closed) Base URL: svn://chrome-svn/chrome/branches/195/src/
Patch Set: Created 11 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « webkit/glue/webplugin.h ('k') | webkit/glue/webplugin_impl.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Property Changes:
Added: svn:mergeinfo
Merged /branches/chrome_webkit_merge_branch/src/webkit/glue/webplugin_impl.h:r3734-4217,4606-5108,5177-5263
Merged /trunk/src/webkit/glue/webplugin_impl.h:r22369
OLDNEW
1 // Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2006-2008 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_GLUE_WEBPLUGIN_IMPL_H_ 5 #ifndef WEBKIT_GLUE_WEBPLUGIN_IMPL_H_
6 #define WEBKIT_GLUE_WEBPLUGIN_IMPL_H_ 6 #define WEBKIT_GLUE_WEBPLUGIN_IMPL_H_
7 7
8 #include <string> 8 #include <string>
9 #include <map> 9 #include <map>
10 #include <vector> 10 #include <vector>
(...skipping 23 matching lines...) Expand all
34 class MouseEvent; 34 class MouseEvent;
35 class ResourceError; 35 class ResourceError;
36 class ResourceResponse; 36 class ResourceResponse;
37 class ScrollView; 37 class ScrollView;
38 class String; 38 class String;
39 class Widget; 39 class Widget;
40 } 40 }
41 41
42 namespace WebKit { 42 namespace WebKit {
43 class WebURLResponse; 43 class WebURLResponse;
44 class WebURLLoader;
44 } 45 }
45 46
46 namespace webkit_glue { 47 namespace webkit_glue {
47 class MultipartResponseDelegate; 48 class MultipartResponseDelegate;
48 } 49 }
49 50
50 // Implements WebCore::Widget functions that WebPluginImpl needs. This class 51 // Implements WebCore::Widget functions that WebPluginImpl needs. This class
51 // exists because it is possible for the plugin widget to be deleted at any 52 // exists because it is possible for the plugin widget to be deleted at any
52 // time because of a delegate javascript call. However we don't want the 53 // time because of a delegate javascript call. However we don't want the
53 // WebPluginImpl to be deleted from under us because it could be lower in the 54 // WebPluginImpl to be deleted from under us because it could be lower in the
(...skipping 203 matching lines...) Expand 10 before | Expand all | Expand 10 after
257 virtual void didSendData(WebKit::WebURLLoader* loader, 258 virtual void didSendData(WebKit::WebURLLoader* loader,
258 unsigned long long bytes_sent, 259 unsigned long long bytes_sent,
259 unsigned long long total_bytes_to_be_sent); 260 unsigned long long total_bytes_to_be_sent);
260 virtual void didReceiveResponse(WebKit::WebURLLoader* loader, 261 virtual void didReceiveResponse(WebKit::WebURLLoader* loader,
261 const WebKit::WebURLResponse& response); 262 const WebKit::WebURLResponse& response);
262 virtual void didReceiveData(WebKit::WebURLLoader* loader, const char *buffer, 263 virtual void didReceiveData(WebKit::WebURLLoader* loader, const char *buffer,
263 int length, long long total_length); 264 int length, long long total_length);
264 virtual void didFinishLoading(WebKit::WebURLLoader* loader); 265 virtual void didFinishLoading(WebKit::WebURLLoader* loader);
265 virtual void didFail(WebKit::WebURLLoader* loader, const WebKit::WebURLError&) ; 266 virtual void didFail(WebKit::WebURLLoader* loader, const WebKit::WebURLError&) ;
266 267
267 // Helper function
268 WebPluginResourceClient* GetClientFromLoader(WebKit::WebURLLoader* loader);
269
270 // Helper function to remove the stored information about a resource 268 // Helper function to remove the stored information about a resource
271 // request given its index in m_clients. 269 // request given its index in m_clients.
272 void RemoveClient(size_t i); 270 void RemoveClient(size_t i);
273 271
274 // Helper function to remove the stored information about a resource 272 // Helper function to remove the stored information about a resource
275 // request given a handle. 273 // request given a handle.
276 void RemoveClient(WebKit::WebURLLoader* loader); 274 void RemoveClient(WebKit::WebURLLoader* loader);
277 275
278 WebCore::Frame* frame() { return webframe_ ? webframe_->frame() : NULL; } 276 WebCore::Frame* frame() { return webframe_ ? webframe_->frame() : NULL; }
279 277
(...skipping 10 matching lines...) Expand all
290 const char* buf, bool is_file_data, 288 const char* buf, bool is_file_data,
291 bool notify, const char* url, 289 bool notify, const char* url,
292 intptr_t notify_data, bool popups_allowed); 290 intptr_t notify_data, bool popups_allowed);
293 291
294 void CancelDocumentLoad(); 292 void CancelDocumentLoad();
295 293
296 void InitiateHTTPRangeRequest(const char* url, const char* range_info, 294 void InitiateHTTPRangeRequest(const char* url, const char* range_info,
297 intptr_t existing_stream, bool notify_needed, 295 intptr_t existing_stream, bool notify_needed,
298 intptr_t notify_data); 296 intptr_t notify_data);
299 297
298 void SetDeferResourceLoading(int resource_id, bool defer);
299
300 // Ignore in-process plugins mode for this flag. 300 // Ignore in-process plugins mode for this flag.
301 bool IsOffTheRecord() { return false; } 301 bool IsOffTheRecord() { return false; }
302 302
303 // Handles HTTP multipart responses, i.e. responses received with a HTTP 303 // Handles HTTP multipart responses, i.e. responses received with a HTTP
304 // status code of 206. 304 // status code of 206.
305 void HandleHttpMultipartResponse(const WebKit::WebURLResponse& response, 305 void HandleHttpMultipartResponse(const WebKit::WebURLResponse& response,
306 WebPluginResourceClient* client); 306 WebPluginResourceClient* client);
307 307
308 void HandleURLRequestInternal(const char *method, bool is_javascript_url, 308 void HandleURLRequestInternal(const char *method, bool is_javascript_url,
309 const char* target, unsigned int len, 309 const char* target, unsigned int len,
(...skipping 16 matching lines...) Expand all
326 // Delayed task for downloading the plugin source URL. 326 // Delayed task for downloading the plugin source URL.
327 void OnDownloadPluginSrcUrl(); 327 void OnDownloadPluginSrcUrl();
328 328
329 struct ClientInfo { 329 struct ClientInfo {
330 int id; 330 int id;
331 WebPluginResourceClient* client; 331 WebPluginResourceClient* client;
332 WebKit::WebURLRequest request; 332 WebKit::WebURLRequest request;
333 linked_ptr<WebKit::WebURLLoader> loader; 333 linked_ptr<WebKit::WebURLLoader> loader;
334 }; 334 };
335 335
336 // Helper functions
337 WebPluginResourceClient* GetClientFromLoader(WebKit::WebURLLoader* loader);
338 ClientInfo* GetClientInfoFromLoader(WebKit::WebURLLoader* loader);
339
336 std::vector<ClientInfo> clients_; 340 std::vector<ClientInfo> clients_;
337 341
338 bool windowless_; 342 bool windowless_;
339 gfx::PluginWindowHandle window_; 343 gfx::PluginWindowHandle window_;
340 WebCore::HTMLPlugInElement* element_; 344 WebCore::HTMLPlugInElement* element_;
341 WebFrameImpl* webframe_; 345 WebFrameImpl* webframe_;
342 346
343 WebPluginDelegate* delegate_; 347 WebPluginDelegate* delegate_;
344 348
345 // Don't use RefPtr here since doing so extends the lifetime of a plugin 349 // Don't use RefPtr here since doing so extends the lifetime of a plugin
(...skipping 25 matching lines...) Expand all
371 375
372 // Holds the list of argument values passed to the plugin. 376 // Holds the list of argument values passed to the plugin.
373 std::vector<std::string> arg_values_; 377 std::vector<std::string> arg_values_;
374 378
375 ScopedRunnableMethodFactory<WebPluginImpl> method_factory_; 379 ScopedRunnableMethodFactory<WebPluginImpl> method_factory_;
376 380
377 DISALLOW_COPY_AND_ASSIGN(WebPluginImpl); 381 DISALLOW_COPY_AND_ASSIGN(WebPluginImpl);
378 }; 382 };
379 383
380 #endif // #ifndef WEBKIT_GLUE_WEBPLUGIN_IMPL_H_ 384 #endif // #ifndef WEBKIT_GLUE_WEBPLUGIN_IMPL_H_
OLDNEW
« no previous file with comments | « webkit/glue/webplugin.h ('k') | webkit/glue/webplugin_impl.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698