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 CHROME_FRAME_URLMON_URL_REQUEST_H_ | 5 #ifndef CHROME_FRAME_URLMON_URL_REQUEST_H_ |
6 #define CHROME_FRAME_URLMON_URL_REQUEST_H_ | 6 #define CHROME_FRAME_URLMON_URL_REQUEST_H_ |
7 | 7 |
8 #include <urlmon.h> | 8 #include <urlmon.h> |
9 #include <atlbase.h> | 9 #include <atlbase.h> |
10 #include <atlcom.h> | 10 #include <atlcom.h> |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
79 friend class base::MessageLoop; | 79 friend class base::MessageLoop; |
80 | 80 |
81 // PluginUrlRequestManager implementation. | 81 // PluginUrlRequestManager implementation. |
82 virtual PluginUrlRequestManager::ThreadSafeFlags GetThreadSafeFlags(); | 82 virtual PluginUrlRequestManager::ThreadSafeFlags GetThreadSafeFlags(); |
83 virtual void StartRequest(int request_id, | 83 virtual void StartRequest(int request_id, |
84 const AutomationURLRequest& request_info); | 84 const AutomationURLRequest& request_info); |
85 virtual void ReadRequest(int request_id, int bytes_to_read); | 85 virtual void ReadRequest(int request_id, int bytes_to_read); |
86 virtual void EndRequest(int request_id); | 86 virtual void EndRequest(int request_id); |
87 virtual void DownloadRequestInHost(int request_id); | 87 virtual void DownloadRequestInHost(int request_id); |
88 virtual void StopAll(); | 88 virtual void StopAll(); |
89 virtual void GetCookiesForUrl(const GURL& url, int cookie_id); | |
90 virtual void SetCookiesForUrl(const GURL& url, const std::string& cookie); | |
91 | 89 |
92 // PluginUrlRequestDelegate implementation | 90 // PluginUrlRequestDelegate implementation |
93 virtual void OnResponseStarted( | 91 virtual void OnResponseStarted( |
94 int request_id, const char* mime_type, const char* headers, int size, | 92 int request_id, const char* mime_type, const char* headers, int size, |
95 base::Time last_modified, const std::string& redirect_url, | 93 base::Time last_modified, const std::string& redirect_url, |
96 int redirect_status, const net::HostPortPair& socket_address, | 94 int redirect_status, const net::HostPortPair& socket_address, |
97 uint64 upload_size); | 95 uint64 upload_size); |
98 virtual void OnReadComplete(int request_id, const std::string& data); | 96 virtual void OnReadComplete(int request_id, const std::string& data); |
99 virtual void OnResponseEnd(int request_id, | 97 virtual void OnResponseEnd(int request_id, |
100 const net::URLRequestStatus& status); | 98 const net::URLRequestStatus& status); |
101 virtual void OnCookiesRetrieved(bool success, const GURL& url, | |
102 const std::string& cookie_string, | |
103 int cookie_id); | |
104 | 99 |
105 // This method is passed as a callback to UrlmonUrlRequest::TerminateBind. | 100 // This method is passed as a callback to UrlmonUrlRequest::TerminateBind. |
106 // We simply forward moniker and bind_ctx to host ActiveX/ActiveDocument, | 101 // We simply forward moniker and bind_ctx to host ActiveX/ActiveDocument, |
107 // so it may start NavigateWithBindContext. | 102 // so it may start NavigateWithBindContext. |
108 void BindTerminated(IMoniker* moniker, IBindCtx* bind_ctx, | 103 void BindTerminated(IMoniker* moniker, IBindCtx* bind_ctx, |
109 IStream* post_data, const char* request_headers); | 104 IStream* post_data, const char* request_headers); |
110 | 105 |
111 // Helper function to initiate a download request in the host. | 106 // Helper function to initiate a download request in the host. |
112 void DownloadRequestInHostHelper(UrlmonUrlRequest* request); | 107 void DownloadRequestInHostHelper(UrlmonUrlRequest* request); |
113 | 108 |
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
146 // The window to be used to fire notifications on. | 141 // The window to be used to fire notifications on. |
147 HWND notification_window_; | 142 HWND notification_window_; |
148 // Set to true if the ChromeFrame instance is running in privileged mode. | 143 // Set to true if the ChromeFrame instance is running in privileged mode. |
149 bool privileged_mode_; | 144 bool privileged_mode_; |
150 // A pointer to the containing object. We maintain a weak reference to avoid | 145 // A pointer to the containing object. We maintain a weak reference to avoid |
151 // lifetime issues. | 146 // lifetime issues. |
152 IUnknown* container_; | 147 IUnknown* container_; |
153 }; | 148 }; |
154 | 149 |
155 #endif // CHROME_FRAME_URLMON_URL_REQUEST_H_ | 150 #endif // CHROME_FRAME_URLMON_URL_REQUEST_H_ |
OLD | NEW |