| 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_DELEGATE_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ | 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ |
| 7 | 7 |
| 8 #include <set> | 8 #include <set> |
| 9 #include <string> | 9 #include <string> |
| 10 | 10 |
| (...skipping 87 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 98 // |*was_blocked| will be set to true if the popup gets blocked, and left | 98 // |*was_blocked| will be set to true if the popup gets blocked, and left |
| 99 // unchanged otherwise. | 99 // unchanged otherwise. |
| 100 virtual void AddNewContents(WebContents* source, | 100 virtual void AddNewContents(WebContents* source, |
| 101 WebContents* new_contents, | 101 WebContents* new_contents, |
| 102 WindowOpenDisposition disposition, | 102 WindowOpenDisposition disposition, |
| 103 const gfx::Rect& initial_rect, | 103 const gfx::Rect& initial_rect, |
| 104 bool user_gesture, | 104 bool user_gesture, |
| 105 bool* was_blocked) {} | 105 bool* was_blocked) {} |
| 106 | 106 |
| 107 // Selects the specified contents, bringing its container to the front. | 107 // Selects the specified contents, bringing its container to the front. |
| 108 virtual void ActivateContents(WebContents* contents) {} | 108 virtual void ActivateContents(WebContents* contents, bool user_gesture) {} |
| 109 | 109 |
| 110 // Deactivates the specified contents by deactivating its container and | 110 // Deactivates the specified contents by deactivating its container and |
| 111 // potentialy moving it to the back of the Z order. | 111 // potentialy moving it to the back of the Z order. |
| 112 virtual void DeactivateContents(WebContents* contents) {} | 112 virtual void DeactivateContents(WebContents* contents) {} |
| 113 | 113 |
| 114 // Notifies the delegate that this contents is starting or is done loading | 114 // Notifies the delegate that this contents is starting or is done loading |
| 115 // some resource. The delegate should use this notification to represent | 115 // some resource. The delegate should use this notification to represent |
| 116 // loading feedback. See WebContents::IsLoading() | 116 // loading feedback. See WebContents::IsLoading() |
| 117 // |to_different_document| will be true unless the load is a fragment | 117 // |to_different_document| will be true unless the load is a fragment |
| 118 // navigation, or triggered by history.pushState/replaceState. | 118 // navigation, or triggered by history.pushState/replaceState. |
| (...skipping 379 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 498 // Called when |this| is no longer the WebContentsDelegate for |source|. | 498 // Called when |this| is no longer the WebContentsDelegate for |source|. |
| 499 void Detach(WebContents* source); | 499 void Detach(WebContents* source); |
| 500 | 500 |
| 501 // The WebContents that this is currently a delegate for. | 501 // The WebContents that this is currently a delegate for. |
| 502 std::set<WebContents*> attached_contents_; | 502 std::set<WebContents*> attached_contents_; |
| 503 }; | 503 }; |
| 504 | 504 |
| 505 } // namespace content | 505 } // namespace content |
| 506 | 506 |
| 507 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ | 507 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ |
| OLD | NEW |