OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 // Defines the Chrome Extensions WebNavigation API functions for observing and | 5 // Defines the Chrome Extensions WebNavigation API functions for observing and |
6 // intercepting navigation events, as specified in the extension JSON API. | 6 // intercepting navigation events, as specified in the extension JSON API. |
7 | 7 |
8 #ifndef CHROME_BROWSER_EXTENSIONS_API_WEB_NAVIGATION_WEB_NAVIGATION_API_H_ | 8 #ifndef CHROME_BROWSER_EXTENSIONS_API_WEB_NAVIGATION_WEB_NAVIGATION_API_H_ |
9 #define CHROME_BROWSER_EXTENSIONS_API_WEB_NAVIGATION_WEB_NAVIGATION_API_H_ | 9 #define CHROME_BROWSER_EXTENSIONS_API_WEB_NAVIGATION_WEB_NAVIGATION_API_H_ |
10 | 10 |
(...skipping 152 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
163 int64 frame_id, | 163 int64 frame_id, |
164 bool is_main_frame, | 164 bool is_main_frame, |
165 const GURL& validated_url, | 165 const GURL& validated_url, |
166 int error_code, | 166 int error_code, |
167 const string16& error_description, | 167 const string16& error_description, |
168 content::RenderViewHost* render_view_host) OVERRIDE; | 168 content::RenderViewHost* render_view_host) OVERRIDE; |
169 virtual void DocumentLoadedInFrame(int64 frame_id) OVERRIDE; | 169 virtual void DocumentLoadedInFrame(int64 frame_id) OVERRIDE; |
170 virtual void DidFinishLoad(int64 frame_id, | 170 virtual void DidFinishLoad(int64 frame_id, |
171 const GURL& validated_url, | 171 const GURL& validated_url, |
172 bool is_main_frame) OVERRIDE; | 172 bool is_main_frame) OVERRIDE; |
| 173 virtual void DidFailLoad(int64 frame_id, |
| 174 const GURL& validated_url, |
| 175 bool is_main_frame, |
| 176 int error_code, |
| 177 const string16& error_description) OVERRIDE; |
173 virtual void DidOpenRequestedURL(content::WebContents* new_contents, | 178 virtual void DidOpenRequestedURL(content::WebContents* new_contents, |
174 const GURL& url, | 179 const GURL& url, |
175 const content::Referrer& referrer, | 180 const content::Referrer& referrer, |
176 WindowOpenDisposition disposition, | 181 WindowOpenDisposition disposition, |
177 content::PageTransition transition, | 182 content::PageTransition transition, |
178 int64 source_frame_id) OVERRIDE; | 183 int64 source_frame_id) OVERRIDE; |
179 virtual void WebContentsDestroyed(content::WebContents* tab) OVERRIDE; | 184 virtual void WebContentsDestroyed(content::WebContents* tab) OVERRIDE; |
180 | 185 |
181 private: | 186 private: |
182 // True if the transition and target url correspond to a reference fragment | 187 // True if the transition and target url correspond to a reference fragment |
(...skipping 91 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
274 // API function that returns the states of all frames in a given tab. | 279 // API function that returns the states of all frames in a given tab. |
275 class GetAllFramesFunction : public SyncExtensionFunction { | 280 class GetAllFramesFunction : public SyncExtensionFunction { |
276 virtual ~GetAllFramesFunction() {} | 281 virtual ~GetAllFramesFunction() {} |
277 virtual bool RunImpl() OVERRIDE; | 282 virtual bool RunImpl() OVERRIDE; |
278 DECLARE_EXTENSION_FUNCTION_NAME("webNavigation.getAllFrames") | 283 DECLARE_EXTENSION_FUNCTION_NAME("webNavigation.getAllFrames") |
279 }; | 284 }; |
280 | 285 |
281 } // namespace extensions | 286 } // namespace extensions |
282 | 287 |
283 #endif // CHROME_BROWSER_EXTENSIONS_API_WEB_NAVIGATION_WEB_NAVIGATION_API_H_ | 288 #endif // CHROME_BROWSER_EXTENSIONS_API_WEB_NAVIGATION_WEB_NAVIGATION_API_H_ |
OLD | NEW |