| OLD | NEW |
| 1 // Copyright (c) 2009 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2009 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_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_DELEGATE_H_ | 5 #ifndef CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_DELEGATE_H_ |
| 6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_DELEGATE_H_ | 6 #define CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <string> | 8 #include <string> |
| 9 #include <vector> | 9 #include <vector> |
| 10 | 10 |
| (...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 138 }; | 138 }; |
| 139 | 139 |
| 140 // RendererManagerment ------------------------------------------------------- | 140 // RendererManagerment ------------------------------------------------------- |
| 141 // Functions for managing switching of Renderers. For TabContents, this is | 141 // Functions for managing switching of Renderers. For TabContents, this is |
| 142 // implemented by the RenderViewHostManager | 142 // implemented by the RenderViewHostManager |
| 143 | 143 |
| 144 class RendererManagement { | 144 class RendererManagement { |
| 145 public: | 145 public: |
| 146 // Notification whether we should close the page, after an explicit call to | 146 // Notification whether we should close the page, after an explicit call to |
| 147 // AttemptToClosePage. This is called before a cross-site request or before | 147 // AttemptToClosePage. This is called before a cross-site request or before |
| 148 // a tab/window is closed, to allow the appropriate renderer to approve or | 148 // a tab/window is closed (as indicated by the first parameter) to allow the |
| 149 // deny the request. |proceed| indicates whether the user chose to proceed. | 149 // appropriate renderer to approve or deny the request. |proceed| indicates |
| 150 virtual void ShouldClosePage(bool proceed) = 0; | 150 // whether the user chose to proceed. |
| 151 virtual void ShouldClosePage(bool for_cross_site_transition, |
| 152 bool proceed) = 0; |
| 151 | 153 |
| 152 // Called by ResourceDispatcherHost when a response for a pending cross-site | 154 // Called by ResourceDispatcherHost when a response for a pending cross-site |
| 153 // request is received. The ResourceDispatcherHost will pause the response | 155 // request is received. The ResourceDispatcherHost will pause the response |
| 154 // until the onunload handler of the previous renderer is run. | 156 // until the onunload handler of the previous renderer is run. |
| 155 virtual void OnCrossSiteResponse(int new_render_process_host_id, | 157 virtual void OnCrossSiteResponse(int new_render_process_host_id, |
| 156 int new_request_id) = 0; | 158 int new_request_id) = 0; |
| 157 | 159 |
| 158 // Called the ResourceDispatcherHost's associate CrossSiteRequestHandler | 160 // Called the ResourceDispatcherHost's associate CrossSiteRequestHandler |
| 159 // when a cross-site navigation has been canceled. | 161 // when a cross-site navigation has been canceled. |
| 160 virtual void OnCrossSiteNavigationCanceled() = 0; | 162 virtual void OnCrossSiteNavigationCanceled() = 0; |
| (...skipping 360 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 521 virtual void LoadStateChanged(const GURL& url, net::LoadState load_state) {} | 523 virtual void LoadStateChanged(const GURL& url, net::LoadState load_state) {} |
| 522 | 524 |
| 523 // Returns true if this view is used to host an external tab container. | 525 // Returns true if this view is used to host an external tab container. |
| 524 virtual bool IsExternalTabContainer() const; | 526 virtual bool IsExternalTabContainer() const; |
| 525 | 527 |
| 526 // The RenderView has inserted one css file into page. | 528 // The RenderView has inserted one css file into page. |
| 527 virtual void DidInsertCSS() {} | 529 virtual void DidInsertCSS() {} |
| 528 }; | 530 }; |
| 529 | 531 |
| 530 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_DELEGATE_H_ | 532 #endif // CHROME_BROWSER_RENDERER_HOST_RENDER_VIEW_HOST_DELEGATE_H_ |
| OLD | NEW |