| 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 #ifndef CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ | 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ |
| 7 | 7 |
| 8 #include "base/process/kill.h" | 8 #include "base/process/kill.h" |
| 9 #include "base/process/process_handle.h" | 9 #include "base/process/process_handle.h" |
| 10 #include "content/common/content_export.h" | 10 #include "content/common/content_export.h" |
| (...skipping 52 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 63 // The WebContents continues to use the RenderViewHost, e.g. when the user | 63 // The WebContents continues to use the RenderViewHost, e.g. when the user |
| 64 // reloads the current page. | 64 // reloads the current page. |
| 65 // When the RenderViewHost is deleted, the RenderViewDeleted method will be | 65 // When the RenderViewHost is deleted, the RenderViewDeleted method will be |
| 66 // invoked. | 66 // invoked. |
| 67 virtual void RenderProcessGone(base::TerminationStatus status) {} | 67 virtual void RenderProcessGone(base::TerminationStatus status) {} |
| 68 | 68 |
| 69 // This method is invoked when a WebContents swaps its render view host with | 69 // This method is invoked when a WebContents swaps its render view host with |
| 70 // another one, possibly changing processes. The RenderViewHost that has | 70 // another one, possibly changing processes. The RenderViewHost that has |
| 71 // been replaced is in |old_render_view_host|, which is NULL if the old RVH | 71 // been replaced is in |old_render_view_host|, which is NULL if the old RVH |
| 72 // was shut down. | 72 // was shut down. |
| 73 virtual void RenderViewHostSwapped(RenderViewHost* old_render_view_host) {} | 73 virtual void RenderViewHostChanged(RenderViewHost* old_host, |
| 74 RenderViewHost* new_host) {} |
| 74 | 75 |
| 75 // This method is invoked after the WebContents decided which RenderViewHost | 76 // This method is invoked after the WebContents decided which RenderViewHost |
| 76 // to use for the next navigation, but before the navigation starts. | 77 // to use for the next navigation, but before the navigation starts. |
| 77 virtual void AboutToNavigateRenderView( | 78 virtual void AboutToNavigateRenderView( |
| 78 RenderViewHost* render_view_host) {} | 79 RenderViewHost* render_view_host) {} |
| 79 | 80 |
| 80 // This method is invoked right after the navigation was initiated. | 81 // This method is invoked right after the navigation was initiated. |
| 81 virtual void NavigateToPendingEntry( | 82 virtual void NavigateToPendingEntry( |
| 82 const GURL& url, | 83 const GURL& url, |
| 83 NavigationController::ReloadType reload_type) {} | 84 NavigationController::ReloadType reload_type) {} |
| (...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 324 void WebContentsImplDestroyed(); | 325 void WebContentsImplDestroyed(); |
| 325 | 326 |
| 326 WebContentsImpl* web_contents_; | 327 WebContentsImpl* web_contents_; |
| 327 | 328 |
| 328 DISALLOW_COPY_AND_ASSIGN(WebContentsObserver); | 329 DISALLOW_COPY_AND_ASSIGN(WebContentsObserver); |
| 329 }; | 330 }; |
| 330 | 331 |
| 331 } // namespace content | 332 } // namespace content |
| 332 | 333 |
| 333 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ | 334 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_OBSERVER_H_ |
| OLD | NEW |