[email protected] | 4fdf674 | 2012-01-10 20:14:36 | [diff] [blame] | 1 | // Copyright (c) 2012 The Chromium Authors. All rights reserved. |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
[email protected] | 674bc59 | 2011-12-20 23:00:42 | [diff] [blame] | 5 | #ifndef CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ |
| 6 | #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 7 | |
[email protected] | 1de2b8b | 2011-06-29 19:38:46 | [diff] [blame] | 8 | #include <set> |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 9 | #include <string> |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 10 | |
| 11 | #include "base/basictypes.h" |
[email protected] | f13b420 | 2012-06-12 23:53:23 | [diff] [blame] | 12 | #include "base/callback.h" |
[email protected] | 26dd01c | 2013-06-12 13:52:13 | [diff] [blame] | 13 | #include "base/strings/string16.h" |
[email protected] | 8d128d6 | 2011-09-13 22:11:57 | [diff] [blame] | 14 | #include "content/common/content_export.h" |
[email protected] | e6e646d | 2011-12-01 00:50:11 | [diff] [blame] | 15 | #include "content/public/browser/navigation_type.h" |
[email protected] | f13b420 | 2012-06-12 23:53:23 | [diff] [blame] | 16 | #include "content/public/common/media_stream_request.h" |
[email protected] | 2905f74 | 2011-10-13 03:51:58 | [diff] [blame] | 17 | #include "content/public/common/page_transition_types.h" |
[email protected] | 4fdf674 | 2012-01-10 20:14:36 | [diff] [blame] | 18 | #include "content/public/common/window_container_type.h" |
[email protected] | 2255a933 | 2013-06-17 05:12:31 | [diff] [blame] | 19 | #include "third_party/WebKit/public/web/WebDragOperation.h" |
[email protected] | da854376 | 2012-03-20 08:52:20 | [diff] [blame] | 20 | #include "third_party/skia/include/core/SkColor.h" |
[email protected] | f47621b | 2013-01-22 20:50:33 | [diff] [blame] | 21 | #include "ui/base/window_open_disposition.h" |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 22 | #include "ui/gfx/native_widget_types.h" |
[email protected] | 59363fc9 | 2012-09-05 03:46:31 | [diff] [blame] | 23 | #include "ui/gfx/rect_f.h" |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 24 | |
[email protected] | 7dba43dc | 2011-11-10 01:57:58 | [diff] [blame] | 25 | class GURL; |
[email protected] | 7dba43dc | 2011-11-10 01:57:58 | [diff] [blame] | 26 | |
[email protected] | 32ded221 | 2011-11-10 18:51:43 | [diff] [blame] | 27 | namespace base { |
[email protected] | a3ef483 | 2013-02-02 05:12:33 | [diff] [blame] | 28 | class FilePath; |
[email protected] | 32ded221 | 2011-11-10 18:51:43 | [diff] [blame] | 29 | class ListValue; |
| 30 | } |
| 31 | |
[email protected] | 3ab9cb8 | 2011-06-03 18:02:07 | [diff] [blame] | 32 | namespace content { |
[email protected] | 3d7474ff | 2011-07-27 17:47:37 | [diff] [blame] | 33 | class BrowserContext; |
[email protected] | da854376 | 2012-03-20 08:52:20 | [diff] [blame] | 34 | class ColorChooser; |
[email protected] | e582fdd | 2011-12-20 16:48:17 | [diff] [blame] | 35 | class DownloadItem; |
[email protected] | 71a88bb | 2013-02-01 22:05:15 | [diff] [blame] | 36 | class JavaScriptDialogManager; |
[email protected] | 691aa2f | 2013-05-28 22:52:04 | [diff] [blame] | 37 | class PageState; |
[email protected] | c0c1c62 | 2012-03-13 04:51:54 | [diff] [blame] | 38 | class RenderViewHost; |
[email protected] | dd673041 | 2013-08-14 15:03:37 | [diff] [blame] | 39 | class SessionStorageNamespace; |
[email protected] | a81343d23 | 2011-12-27 07:39:20 | [diff] [blame] | 40 | class WebContents; |
[email protected] | 8ff00d7 | 2012-10-23 19:12:21 | [diff] [blame] | 41 | class WebContentsImpl; |
[email protected] | 8bc5ff0 | 2013-11-29 06:34:03 | [diff] [blame] | 42 | struct ColorSuggestion; |
[email protected] | 35be7ec | 2012-02-12 20:42:51 | [diff] [blame] | 43 | struct ContextMenuParams; |
[email protected] | dc293a7 | 2013-07-01 11:11:22 | [diff] [blame] | 44 | struct DropData; |
[email protected] | e582fdd | 2011-12-20 16:48:17 | [diff] [blame] | 45 | struct FileChooserParams; |
[email protected] | b87ee52 | 2012-05-18 15:16:54 | [diff] [blame] | 46 | struct NativeWebKeyboardEvent; |
[email protected] | 44e55b01 | 2013-07-23 14:21:56 | [diff] [blame] | 47 | struct Referrer; |
[email protected] | d583e3f2 | 2011-12-27 21:38:17 | [diff] [blame] | 48 | struct SSLStatus; |
[email protected] | 3ab9cb8 | 2011-06-03 18:02:07 | [diff] [blame] | 49 | } |
| 50 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 51 | namespace gfx { |
| 52 | class Point; |
| 53 | class Rect; |
| 54 | class Size; |
| 55 | } |
| 56 | |
[email protected] | 180ef24 | 2013-11-07 06:50:46 | [diff] [blame] | 57 | namespace blink { |
[email protected] | 04bce56 | 2014-01-30 05:34:54 | [diff] [blame] | 58 | class WebGestureEvent; |
[email protected] | 1638338 | 2012-09-05 23:57:26 | [diff] [blame] | 59 | class WebLayer; |
[email protected] | 453c1b2 | 2013-07-23 09:31:48 | [diff] [blame] | 60 | struct WebWindowFeatures; |
[email protected] | 1638338 | 2012-09-05 23:57:26 | [diff] [blame] | 61 | } |
| 62 | |
[email protected] | 674bc59 | 2011-12-20 23:00:42 | [diff] [blame] | 63 | namespace content { |
| 64 | |
[email protected] | e5d549d | 2011-12-28 01:29:20 | [diff] [blame] | 65 | struct OpenURLParams; |
| 66 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 67 | // Objects implement this interface to get notified about changes in the |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 68 | // WebContents and to provide necessary functionality. |
[email protected] | 674bc59 | 2011-12-20 23:00:42 | [diff] [blame] | 69 | class CONTENT_EXPORT WebContentsDelegate { |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 70 | public: |
[email protected] | 674bc59 | 2011-12-20 23:00:42 | [diff] [blame] | 71 | WebContentsDelegate(); |
[email protected] | 1de2b8b | 2011-06-29 19:38:46 | [diff] [blame] | 72 | |
[email protected] | e5d549d | 2011-12-28 01:29:20 | [diff] [blame] | 73 | // Opens a new URL inside the passed in WebContents (if source is 0 open |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 74 | // in the current front-most tab), unless |disposition| indicates the url |
| 75 | // should be opened in a new tab or window. |
| 76 | // |
| 77 | // A NULL source indicates the current tab (callers should probably use |
| 78 | // OpenURL() for these cases which does it for you). |
[email protected] | 00c37fc | 2011-08-02 00:22:50 | [diff] [blame] | 79 | |
[email protected] | e5d549d | 2011-12-28 01:29:20 | [diff] [blame] | 80 | // Returns the WebContents the URL is opened in, or NULL if the URL wasn't |
[email protected] | 992e454 | 2011-07-20 23:09:25 | [diff] [blame] | 81 | // opened immediately. |
[email protected] | e5d549d | 2011-12-28 01:29:20 | [diff] [blame] | 82 | virtual WebContents* OpenURLFromTab(WebContents* source, |
[email protected] | 00c37fc | 2011-08-02 00:22:50 | [diff] [blame] | 83 | const OpenURLParams& params); |
| 84 | |
[email protected] | ca13a44 | 2012-04-17 14:00:12 | [diff] [blame] | 85 | // Called to inform the delegate that the WebContents's navigation state |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 86 | // changed. The |changed_flags| indicates the parts of the navigation state |
| 87 | // that have been updated, and is any combination of the |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 88 | // |WebContents::InvalidateTypes| bits. |
| 89 | virtual void NavigationStateChanged(const WebContents* source, |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 90 | unsigned changed_flags) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 91 | |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 92 | // Creates a new tab with the already-created WebContents 'new_contents'. |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 93 | // The window for the added contents should be reparented correctly when this |
[email protected] | dc0fd43 | 2013-08-27 15:29:21 | [diff] [blame] | 94 | // method returns. If |disposition| is NEW_POPUP, |initial_pos| should hold |
| 95 | // the initial position. If |was_blocked| is non-NULL, then |*was_blocked| |
| 96 | // will be set to true if the popup gets blocked, and left unchanged |
| 97 | // otherwise. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 98 | virtual void AddNewContents(WebContents* source, |
| 99 | WebContents* new_contents, |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 100 | WindowOpenDisposition disposition, |
| 101 | const gfx::Rect& initial_pos, |
[email protected] | eda238a1 | 2012-09-07 23:44:00 | [diff] [blame] | 102 | bool user_gesture, |
| 103 | bool* was_blocked) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 104 | |
| 105 | // Selects the specified contents, bringing its container to the front. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 106 | virtual void ActivateContents(WebContents* contents) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 107 | |
| 108 | // Deactivates the specified contents by deactivating its container and |
| 109 | // potentialy moving it to the back of the Z order. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 110 | virtual void DeactivateContents(WebContents* contents) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 111 | |
| 112 | // Notifies the delegate that this contents is starting or is done loading |
| 113 | // some resource. The delegate should use this notification to represent |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 114 | // loading feedback. See WebContents::IsLoading() |
[email protected] | e3b10d1 | 2014-03-28 16:06:09 | [diff] [blame] | 115 | // |to_different_document| will be true unless the load is a fragment |
| 116 | // navigation, or triggered by history.pushState/replaceState. |
| 117 | virtual void LoadingStateChanged(WebContents* source, |
| 118 | bool to_different_document) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 119 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 120 | // Notifies the delegate that the page has made some progress loading. |
| 121 | // |progress| is a value between 0.0 (nothing loaded) to 1.0 (page fully |
| 122 | // loaded). |
[email protected] | b3996ba | 2012-08-08 00:39:13 | [diff] [blame] | 123 | virtual void LoadProgressChanged(WebContents* source, |
| 124 | double progress) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 125 | |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 126 | // Request the delegate to close this web contents, and do whatever cleanup |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 127 | // it needs to do. |
[email protected] | a81343d23 | 2011-12-27 07:39:20 | [diff] [blame] | 128 | virtual void CloseContents(WebContents* source) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 129 | |
[email protected] | cd9ed79d | 2011-11-15 19:22:57 | [diff] [blame] | 130 | // Informs the delegate that the underlying RenderViewHost has been swapped |
| 131 | // out so it can perform any cleanup necessary. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 132 | virtual void SwappedOut(WebContents* source) {} |
[email protected] | cd9ed79d | 2011-11-15 19:22:57 | [diff] [blame] | 133 | |
[email protected] | ca13a44 | 2012-04-17 14:00:12 | [diff] [blame] | 134 | // Request the delegate to move this WebContents to the specified position |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 135 | // in screen coordinates. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 136 | virtual void MoveContents(WebContents* source, const gfx::Rect& pos) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 137 | |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 138 | // Called to determine if the WebContents is contained in a popup window |
[email protected] | b35b26b3 | 2011-05-05 20:35:14 | [diff] [blame] | 139 | // or a panel window. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 140 | virtual bool IsPopupOrPanel(const WebContents* source) const; |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 141 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 142 | // Notification that the target URL has changed. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 143 | virtual void UpdateTargetURL(WebContents* source, |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 144 | int32 page_id, |
| 145 | const GURL& url) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 146 | |
| 147 | // Notification that there was a mouse event, along with the absolute |
| 148 | // coordinates of the mouse pointer and whether it was a normal motion event |
| 149 | // (otherwise, the pointer left the contents area). |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 150 | virtual void ContentsMouseEvent(WebContents* source, |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 151 | const gfx::Point& location, |
| 152 | bool motion) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 153 | |
| 154 | // Request the delegate to change the zoom level of the current tab. |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 155 | virtual void ContentsZoomChange(bool zoom_in) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 156 | |
[email protected] | 06731026 | 2012-11-22 14:30:41 | [diff] [blame] | 157 | // Called to determine if the WebContents can be overscrolled with touch/wheel |
| 158 | // gestures. |
| 159 | virtual bool CanOverscrollContent() const; |
| 160 | |
[email protected] | 888878e8 | 2013-07-24 22:49:40 | [diff] [blame] | 161 | // Callback that allows vertical overscroll activies to be communicated to the |
| 162 | // delegate. |
| 163 | virtual void OverscrollUpdate(int delta_y) {} |
| 164 | |
[email protected] | b7a756d4 | 2012-01-23 18:08:17 | [diff] [blame] | 165 | // Return the rect where to display the resize corner, if any, otherwise |
| 166 | // an empty rect. |
| 167 | virtual gfx::Rect GetRootWindowResizerRect() const; |
| 168 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 169 | // Invoked prior to showing before unload handler confirmation dialog. |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 170 | virtual void WillRunBeforeUnloadConfirm() {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 171 | |
| 172 | // Returns true if javascript dialogs and unload alerts are suppressed. |
| 173 | // Default is false. |
| 174 | virtual bool ShouldSuppressDialogs(); |
| 175 | |
[email protected] | a796f20 | 2012-05-30 14:14:25 | [diff] [blame] | 176 | // Add a message to the console. Returning true indicates that the delegate |
| 177 | // handled the message. If false is returned the default logging mechanism |
| 178 | // will be used for the message. |
[email protected] | 0c940663 | 2013-02-08 01:13:33 | [diff] [blame] | 179 | virtual bool AddMessageToConsole(WebContents* source, |
[email protected] | a796f20 | 2012-05-30 14:14:25 | [diff] [blame] | 180 | int32 level, |
[email protected] | fcf75d4 | 2013-12-03 20:11:26 | [diff] [blame] | 181 | const base::string16& message, |
[email protected] | a796f20 | 2012-05-30 14:14:25 | [diff] [blame] | 182 | int32 line_no, |
[email protected] | fcf75d4 | 2013-12-03 20:11:26 | [diff] [blame] | 183 | const base::string16& source_id); |
[email protected] | a796f20 | 2012-05-30 14:14:25 | [diff] [blame] | 184 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 185 | // Tells us that we've finished firing this tab's beforeunload event. |
| 186 | // The proceed bool tells us whether the user chose to proceed closing the |
[email protected] | a2c92a1c | 2012-04-03 12:32:14 | [diff] [blame] | 187 | // tab. Returns true if the tab can continue on firing its unload event. |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 188 | // If we're closing the entire browser, then we'll want to delay firing |
| 189 | // unload events until all the beforeunload events have fired. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 190 | virtual void BeforeUnloadFired(WebContents* tab, |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 191 | bool proceed, |
| 192 | bool* proceed_to_fire_unload); |
| 193 | |
[email protected] | 0c940663 | 2013-02-08 01:13:33 | [diff] [blame] | 194 | // Returns true if the location bar should be focused by default rather than |
[email protected] | af4b5f9 | 2013-03-05 07:48:38 | [diff] [blame] | 195 | // the page contents. NOTE: this is only used if WebContents can't determine |
| 196 | // for itself whether the location bar should be focused by default. For a |
| 197 | // complete check, you should use WebContents::FocusLocationBarByDefault(). |
[email protected] | 0c940663 | 2013-02-08 01:13:33 | [diff] [blame] | 198 | virtual bool ShouldFocusLocationBarByDefault(WebContents* source); |
| 199 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 200 | // Sets focus to the location bar or some other place that is appropriate. |
| 201 | // This is called when the tab wants to encourage user input, like for the |
| 202 | // new tab page. |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 203 | virtual void SetFocusToLocationBar(bool select_all) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 204 | |
| 205 | // Returns whether the page should be focused when transitioning from crashed |
| 206 | // to live. Default is true. |
| 207 | virtual bool ShouldFocusPageAfterCrash(); |
| 208 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 209 | // This is called when WebKit tells us that it is done tabbing through |
[email protected] | 674bc59 | 2011-12-20 23:00:42 | [diff] [blame] | 210 | // controls on the page. Provides a way for WebContentsDelegates to handle |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 211 | // this. Returns true if the delegate successfully handled it. |
[email protected] | 0c940663 | 2013-02-08 01:13:33 | [diff] [blame] | 212 | virtual bool TakeFocus(WebContents* source, |
[email protected] | b3996ba | 2012-08-08 00:39:13 | [diff] [blame] | 213 | bool reverse); |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 214 | |
| 215 | // Invoked when the page loses mouse capture. |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 216 | virtual void LostCapture() {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 217 | |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 218 | // Notification that |contents| has gained focus. |
| 219 | virtual void WebContentsFocused(WebContents* contents) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 220 | |
[email protected] | 68649314 | 2011-07-15 21:47:22 | [diff] [blame] | 221 | // Asks the delegate if the given tab can download. |
[email protected] | f85f503 | 2013-04-03 09:01:54 | [diff] [blame] | 222 | // Invoking the |callback| synchronously is OK. |
| 223 | virtual void CanDownload(RenderViewHost* render_view_host, |
[email protected] | c0c1c62 | 2012-03-13 04:51:54 | [diff] [blame] | 224 | int request_id, |
[email protected] | f85f503 | 2013-04-03 09:01:54 | [diff] [blame] | 225 | const std::string& request_method, |
| 226 | const base::Callback<void(bool)>& callback); |
[email protected] | 68649314 | 2011-07-15 21:47:22 | [diff] [blame] | 227 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 228 | // Return much extra vertical space should be allotted to the |
| 229 | // render view widget during various animations (e.g. infobar closing). |
| 230 | // This is used to make painting look smoother. |
| 231 | virtual int GetExtraRenderViewHeight() const; |
| 232 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 233 | // Returns true if the context menu operation was handled by the delegate. |
[email protected] | 63028f5 | 2014-02-10 16:45:40 | [diff] [blame] | 234 | virtual bool HandleContextMenu(const content::ContextMenuParams& params); |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 235 | |
[email protected] | ca13a44 | 2012-04-17 14:00:12 | [diff] [blame] | 236 | // Opens source view for given WebContents that is navigated to the given |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 237 | // page url. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 238 | virtual void ViewSourceForTab(WebContents* source, const GURL& page_url); |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 239 | |
[email protected] | 932b7a1 | 2011-03-09 12:50:27 | [diff] [blame] | 240 | // Opens source view for the given subframe. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 241 | virtual void ViewSourceForFrame(WebContents* source, |
[email protected] | 932b7a1 | 2011-03-09 12:50:27 | [diff] [blame] | 242 | const GURL& url, |
[email protected] | 691aa2f | 2013-05-28 22:52:04 | [diff] [blame] | 243 | const PageState& page_state); |
[email protected] | 932b7a1 | 2011-03-09 12:50:27 | [diff] [blame] | 244 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 245 | // Allows delegates to handle keyboard events before sending to the renderer. |
| 246 | // Returns true if the |event| was handled. Otherwise, if the |event| would be |
| 247 | // handled in HandleKeyboardEvent() method as a normal keyboard shortcut, |
| 248 | // |*is_keyboard_shortcut| should be set to true. |
[email protected] | b3996ba | 2012-08-08 00:39:13 | [diff] [blame] | 249 | virtual bool PreHandleKeyboardEvent(WebContents* source, |
| 250 | const NativeWebKeyboardEvent& event, |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 251 | bool* is_keyboard_shortcut); |
| 252 | |
| 253 | // Allows delegates to handle unhandled keyboard messages coming back from |
| 254 | // the renderer. |
[email protected] | b3996ba | 2012-08-08 00:39:13 | [diff] [blame] | 255 | virtual void HandleKeyboardEvent(WebContents* source, |
| 256 | const NativeWebKeyboardEvent& event) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 257 | |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 258 | virtual void HandleMouseDown() {} |
| 259 | virtual void HandleMouseUp() {} |
[email protected] | 590a634e | 2012-07-19 16:38:23 | [diff] [blame] | 260 | |
| 261 | // Handles activation resulting from a pointer event (e.g. when mouse is |
| 262 | // pressed, or a touch-gesture begins). |
| 263 | virtual void HandlePointerActivate() {} |
| 264 | |
[email protected] | 04bce56 | 2014-01-30 05:34:54 | [diff] [blame] | 265 | // Allows delegates to handle gesture events before sending to the renderer. |
| 266 | // Returns true if the |event| was handled and thus shouldn't be processed |
| 267 | // by the renderer's event handler. Note that the touch events that create |
| 268 | // the gesture are always passed to the renderer since the gesture is created |
| 269 | // and dispatched after the touches return without being "preventDefault()"ed. |
| 270 | virtual bool PreHandleGestureEvent( |
| 271 | WebContents* source, |
| 272 | const blink::WebGestureEvent& event); |
| 273 | |
[email protected] | 590a634e | 2012-07-19 16:38:23 | [diff] [blame] | 274 | virtual void HandleGestureBegin() {} |
| 275 | virtual void HandleGestureEnd() {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 276 | |
[email protected] | 090550f | 2013-06-11 15:04:47 | [diff] [blame] | 277 | // Called when an external drag event enters the web contents window. Return |
| 278 | // true to allow dragging and dropping on the web contents window or false to |
| 279 | // cancel the operation. This method is used by Chromium Embedded Framework. |
| 280 | virtual bool CanDragEnter(WebContents* source, |
[email protected] | dc293a7 | 2013-07-01 11:11:22 | [diff] [blame] | 281 | const DropData& data, |
[email protected] | 180ef24 | 2013-11-07 06:50:46 | [diff] [blame] | 282 | blink::WebDragOperationsMask operations_allowed); |
[email protected] | 090550f | 2013-06-11 15:04:47 | [diff] [blame] | 283 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 284 | // Render view drag n drop ended. |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 285 | virtual void DragEnded() {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 286 | |
| 287 | // Shows the repost form confirmation dialog box. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 288 | virtual void ShowRepostFormWarningDialog(WebContents* source) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 289 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 290 | // Allows delegate to override navigation to the history entries. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 291 | // Returns true to allow WebContents to continue with the default processing. |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 292 | virtual bool OnGoToEntryOffset(int offset); |
| 293 | |
[email protected] | 4fdf674 | 2012-01-10 20:14:36 | [diff] [blame] | 294 | // Allows delegate to control whether a WebContents will be created. Returns |
[email protected] | 03b6d55 | 2012-03-29 04:03:01 | [diff] [blame] | 295 | // true to allow the creation. Default is to allow it. In cases where the |
| 296 | // delegate handles the creation/navigation itself, it will use |target_url|. |
[email protected] | f1cd336 | 2014-01-07 20:43:01 | [diff] [blame] | 297 | // The embedder has to synchronously adopt |route_id| or else the view will |
| 298 | // be destroyed. |
[email protected] | 4fdf674 | 2012-01-10 20:14:36 | [diff] [blame] | 299 | virtual bool ShouldCreateWebContents( |
| 300 | WebContents* web_contents, |
| 301 | int route_id, |
| 302 | WindowContainerType window_container_type, |
[email protected] | fcf75d4 | 2013-12-03 20:11:26 | [diff] [blame] | 303 | const base::string16& frame_name, |
[email protected] | 4543b67c | 2013-07-11 18:18:36 | [diff] [blame] | 304 | const GURL& target_url, |
[email protected] | dd673041 | 2013-08-14 15:03:37 | [diff] [blame] | 305 | const std::string& partition_id, |
| 306 | SessionStorageNamespace* session_storage_namespace); |
[email protected] | 4fdf674 | 2012-01-10 20:14:36 | [diff] [blame] | 307 | |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 308 | // Notifies the delegate about the creation of a new WebContents. This |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 309 | // typically happens when popups are created. |
[email protected] | 4fdf674 | 2012-01-10 20:14:36 | [diff] [blame] | 310 | virtual void WebContentsCreated(WebContents* source_contents, |
[email protected] | a7531d77 | 2014-03-25 16:15:07 | [diff] [blame] | 311 | int opener_render_frame_id, |
[email protected] | fcf75d4 | 2013-12-03 20:11:26 | [diff] [blame] | 312 | const base::string16& frame_name, |
[email protected] | 4fdf674 | 2012-01-10 20:14:36 | [diff] [blame] | 313 | const GURL& target_url, |
| 314 | WebContents* new_contents) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 315 | |
[email protected] | 5545290 | 2011-06-01 21:57:47 | [diff] [blame] | 316 | // Notification that the tab is hung. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 317 | virtual void RendererUnresponsive(WebContents* source) {} |
[email protected] | 5545290 | 2011-06-01 21:57:47 | [diff] [blame] | 318 | |
| 319 | // Notification that the tab is no longer hung. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 320 | virtual void RendererResponsive(WebContents* source) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 321 | |
| 322 | // Notification that a worker associated with this tab has crashed. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 323 | virtual void WorkerCrashed(WebContents* source) {} |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 324 | |
[email protected] | 09b2934 | 2011-06-24 19:18:48 | [diff] [blame] | 325 | // Invoked when a main fram navigation occurs. |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 326 | virtual void DidNavigateMainFramePostCommit(WebContents* source) {} |
[email protected] | 93f230e0 | 2011-06-01 14:40:00 | [diff] [blame] | 327 | |
[email protected] | 09b2934 | 2011-06-24 19:18:48 | [diff] [blame] | 328 | // Invoked when navigating to a pending entry. When invoked the |
| 329 | // NavigationController has configured its pending entry, but it has not yet |
| 330 | // been committed. |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 331 | virtual void DidNavigateToPendingEntry(WebContents* source) {} |
[email protected] | 93f230e0 | 2011-06-01 14:40:00 | [diff] [blame] | 332 | |
[email protected] | 71a88bb | 2013-02-01 22:05:15 | [diff] [blame] | 333 | // Returns a pointer to a service to manage JavaScript dialogs. May return |
[email protected] | 51da7e3 | 2012-01-30 19:24:52 | [diff] [blame] | 334 | // NULL in which case dialogs aren't shown. |
[email protected] | 71a88bb | 2013-02-01 22:05:15 | [diff] [blame] | 335 | virtual JavaScriptDialogManager* GetJavaScriptDialogManager(); |
[email protected] | 3ab9cb8 | 2011-06-03 18:02:07 | [diff] [blame] | 336 | |
[email protected] | da854376 | 2012-03-20 08:52:20 | [diff] [blame] | 337 | // Called when color chooser should open. Returns the opened color chooser. |
[email protected] | 820957a | 2014-01-14 14:56:30 | [diff] [blame] | 338 | // Returns NULL if we failed to open the color chooser (e.g. when there is a |
| 339 | // ColorChooserDialog already open on Windows). Ownership of the returned |
| 340 | // pointer is transferred to the caller. |
[email protected] | 8bc5ff0 | 2013-11-29 06:34:03 | [diff] [blame] | 341 | virtual ColorChooser* OpenColorChooser( |
| 342 | WebContents* web_contents, |
| 343 | SkColor color, |
| 344 | const std::vector<ColorSuggestion>& suggestions); |
[email protected] | da854376 | 2012-03-20 08:52:20 | [diff] [blame] | 345 | |
[email protected] | 3a29a6e | 2011-08-24 18:26:21 | [diff] [blame] | 346 | // Called when a file selection is to be done. |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 347 | virtual void RunFileChooser(WebContents* web_contents, |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 348 | const FileChooserParams& params) {} |
[email protected] | 3a29a6e | 2011-08-24 18:26:21 | [diff] [blame] | 349 | |
| 350 | // Request to enumerate a directory. This is equivalent to running the file |
| 351 | // chooser in directory-enumeration mode and having the user select the given |
| 352 | // directory. |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 353 | virtual void EnumerateDirectory(WebContents* web_contents, |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 354 | int request_id, |
[email protected] | a3ef483 | 2013-02-02 05:12:33 | [diff] [blame] | 355 | const base::FilePath& path) {} |
[email protected] | 3a29a6e | 2011-08-24 18:26:21 | [diff] [blame] | 356 | |
[email protected] | 4aebbca | 2013-09-17 22:26:49 | [diff] [blame] | 357 | // Returns true if the delegate will embed a WebContents-owned fullscreen |
| 358 | // render widget. In this case, the delegate may access the widget by calling |
| 359 | // WebContents::GetFullscreenRenderWidgetHostView(). If false is returned, |
| 360 | // WebContents will be responsible for showing the fullscreen widget. |
| 361 | virtual bool EmbedsFullscreenWidget() const; |
| 362 | |
[email protected] | 8a5e0ca | 2011-08-25 06:30:47 | [diff] [blame] | 363 | // Called when the renderer puts a tab into or out of fullscreen mode. |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 364 | virtual void ToggleFullscreenModeForTab(WebContents* web_contents, |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 365 | bool enter_fullscreen) {} |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 366 | virtual bool IsFullscreenForTabOrPending( |
| 367 | const WebContents* web_contents) const; |
[email protected] | 8a5e0ca | 2011-08-25 06:30:47 | [diff] [blame] | 368 | |
[email protected] | 7d18902 | 2011-08-25 22:54:20 | [diff] [blame] | 369 | // Register a new handler for URL requests with the given scheme. |
[email protected] | 3a3b75a | 2012-06-01 08:38:36 | [diff] [blame] | 370 | // |user_gesture| is true if the registration is made in the context of a user |
| 371 | // gesture. |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 372 | virtual void RegisterProtocolHandler(WebContents* web_contents, |
[email protected] | 7d18902 | 2011-08-25 22:54:20 | [diff] [blame] | 373 | const std::string& protocol, |
| 374 | const GURL& url, |
[email protected] | fcf75d4 | 2013-12-03 20:11:26 | [diff] [blame] | 375 | const base::string16& title, |
[email protected] | 3a3b75a | 2012-06-01 08:38:36 | [diff] [blame] | 376 | bool user_gesture) {} |
[email protected] | 7d18902 | 2011-08-25 22:54:20 | [diff] [blame] | 377 | |
[email protected] | b888919c | 2011-09-02 00:32:16 | [diff] [blame] | 378 | // Result of string search in the page. This includes the number of matches |
| 379 | // found and the selection rect (in screen coordinates) for the string found. |
| 380 | // If |final_update| is false, it indicates that more results follow. |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 381 | virtual void FindReply(WebContents* web_contents, |
[email protected] | b888919c | 2011-09-02 00:32:16 | [diff] [blame] | 382 | int request_id, |
| 383 | int number_of_matches, |
| 384 | const gfx::Rect& selection_rect, |
| 385 | int active_match_ordinal, |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 386 | bool final_update) {} |
[email protected] | b888919c | 2011-09-02 00:32:16 | [diff] [blame] | 387 | |
[email protected] | 59363fc9 | 2012-09-05 03:46:31 | [diff] [blame] | 388 | #if defined(OS_ANDROID) |
| 389 | // Provides the rects of the current find-in-page matches. |
| 390 | // Sent as a reply to RequestFindMatchRects. |
| 391 | virtual void FindMatchRectsReply(WebContents* web_contents, |
| 392 | int version, |
| 393 | const std::vector<gfx::RectF>& rects, |
| 394 | const gfx::RectF& active_rect) {} |
[email protected] | 59363fc9 | 2012-09-05 03:46:31 | [diff] [blame] | 395 | #endif |
| 396 | |
[email protected] | 0548c535 | 2011-09-07 00:33:33 | [diff] [blame] | 397 | // Invoked when the preferred size of the contents has been changed. |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 398 | virtual void UpdatePreferredSize(WebContents* web_contents, |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 399 | const gfx::Size& pref_size) {} |
[email protected] | 0548c535 | 2011-09-07 00:33:33 | [diff] [blame] | 400 | |
[email protected] | 61e2b3cc | 2012-03-02 16:13:34 | [diff] [blame] | 401 | // Invoked when the contents auto-resized and the container should match it. |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 402 | virtual void ResizeDueToAutoResize(WebContents* web_contents, |
[email protected] | 61e2b3cc | 2012-03-02 16:13:34 | [diff] [blame] | 403 | const gfx::Size& new_size) {} |
| 404 | |
[email protected] | 32ded221 | 2011-11-10 18:51:43 | [diff] [blame] | 405 | // Notification message from HTML UI. |
[email protected] | 3bbacc5b | 2012-04-17 17:46:15 | [diff] [blame] | 406 | virtual void WebUISend(WebContents* web_contents, |
[email protected] | 32ded221 | 2011-11-10 18:51:43 | [diff] [blame] | 407 | const GURL& source_url, |
| 408 | const std::string& name, |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 409 | const base::ListValue& args) {} |
[email protected] | 32ded221 | 2011-11-10 18:51:43 | [diff] [blame] | 410 | |
[email protected] | e962111 | 2011-10-17 05:38:37 | [diff] [blame] | 411 | // Requests to lock the mouse. Once the request is approved or rejected, |
| 412 | // GotResponseToLockMouseRequest() will be called on the requesting tab |
| 413 | // contents. |
[email protected] | 42252e0 | 2012-04-26 16:29:39 | [diff] [blame] | 414 | virtual void RequestToLockMouse(WebContents* web_contents, |
[email protected] | a9c81f0 | 2012-06-01 00:15:44 | [diff] [blame] | 415 | bool user_gesture, |
[email protected] | f13b420 | 2012-06-12 23:53:23 | [diff] [blame] | 416 | bool last_unlocked_by_target) {} |
[email protected] | e962111 | 2011-10-17 05:38:37 | [diff] [blame] | 417 | |
| 418 | // Notification that the page has lost the mouse lock. |
[email protected] | 229eb7e | 2011-12-23 01:04:08 | [diff] [blame] | 419 | virtual void LostMouseLock() {} |
[email protected] | e962111 | 2011-10-17 05:38:37 | [diff] [blame] | 420 | |
[email protected] | f13b420 | 2012-06-12 23:53:23 | [diff] [blame] | 421 | // Asks permission to use the camera and/or microphone. If permission is |
| 422 | // granted, a call should be made to |callback| with the devices. If the |
| 423 | // request is denied, a call should be made to |callback| with an empty list |
| 424 | // of devices. |request| has the details of the request (e.g. which of audio |
| 425 | // and/or video devices are requested, and lists of available devices). |
| 426 | virtual void RequestMediaAccessPermission( |
| 427 | WebContents* web_contents, |
[email protected] | 33662e5 | 2013-01-07 21:31:09 | [diff] [blame] | 428 | const MediaStreamRequest& request, |
[email protected] | db3cd913 | 2013-09-03 17:39:23 | [diff] [blame] | 429 | const MediaResponseCallback& callback); |
[email protected] | f13b420 | 2012-06-12 23:53:23 | [diff] [blame] | 430 | |
[email protected] | 8c8fc29 | 2012-11-23 18:57:16 | [diff] [blame] | 431 | // Requests permission to access the PPAPI broker. The delegate should return |
| 432 | // true and call the passed in |callback| with the result, or return false |
| 433 | // to indicate that it does not support asking for permission. |
| 434 | virtual bool RequestPpapiBrokerPermission( |
| 435 | WebContents* web_contents, |
| 436 | const GURL& url, |
[email protected] | a3ef483 | 2013-02-02 05:12:33 | [diff] [blame] | 437 | const base::FilePath& plugin_path, |
[email protected] | 8c8fc29 | 2012-11-23 18:57:16 | [diff] [blame] | 438 | const base::Callback<void(bool)>& callback); |
| 439 | |
[email protected] | dc0fd43 | 2013-08-27 15:29:21 | [diff] [blame] | 440 | // Returns the size for the new render view created for the pending entry in |
| 441 | // |web_contents|; if there's no size, returns an empty size. |
| 442 | // This is optional for implementations of WebContentsDelegate; if the |
| 443 | // delegate doesn't provide a size, the current WebContentsView's size will be |
| 444 | // used. |
| 445 | virtual gfx::Size GetSizeForNewRenderView( |
| 446 | const WebContents* web_contents) const; |
| 447 | |
[email protected] | edc3af8 | 2013-12-12 21:24:07 | [diff] [blame] | 448 | // Notification that validation of a form displayed by the |web_contents| |
| 449 | // has failed. There can only be one message per |web_contents| at a time. |
| 450 | virtual void ShowValidationMessage(WebContents* web_contents, |
| 451 | const gfx::Rect& anchor_in_root_view, |
[email protected] | 6ff9c8f | 2013-12-20 09:05:29 | [diff] [blame] | 452 | const base::string16& main_text, |
| 453 | const base::string16& sub_text) {} |
[email protected] | edc3af8 | 2013-12-12 21:24:07 | [diff] [blame] | 454 | |
| 455 | // Notification that the delegate should hide any showing form validation |
| 456 | // message. |
| 457 | virtual void HideValidationMessage(WebContents* web_contents) {} |
| 458 | |
| 459 | // Notification that the form element that triggered the validation failure |
| 460 | // has moved. |
| 461 | virtual void MoveValidationMessage(WebContents* web_contents, |
| 462 | const gfx::Rect& anchor_in_root_view) {} |
| 463 | |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 464 | protected: |
[email protected] | 674bc59 | 2011-12-20 23:00:42 | [diff] [blame] | 465 | virtual ~WebContentsDelegate(); |
[email protected] | 1de2b8b | 2011-06-29 19:38:46 | [diff] [blame] | 466 | |
| 467 | private: |
[email protected] | 8ff00d7 | 2012-10-23 19:12:21 | [diff] [blame] | 468 | friend class WebContentsImpl; |
[email protected] | 1de2b8b | 2011-06-29 19:38:46 | [diff] [blame] | 469 | |
[email protected] | 674bc59 | 2011-12-20 23:00:42 | [diff] [blame] | 470 | // Called when |this| becomes the WebContentsDelegate for |source|. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 471 | void Attach(WebContents* source); |
[email protected] | 1de2b8b | 2011-06-29 19:38:46 | [diff] [blame] | 472 | |
[email protected] | 674bc59 | 2011-12-20 23:00:42 | [diff] [blame] | 473 | // Called when |this| is no longer the WebContentsDelegate for |source|. |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 474 | void Detach(WebContents* source); |
[email protected] | 1de2b8b | 2011-06-29 19:38:46 | [diff] [blame] | 475 | |
[email protected] | 2a6bc3e | 2011-12-28 23:51:33 | [diff] [blame] | 476 | // The WebContents that this is currently a delegate for. |
| 477 | std::set<WebContents*> attached_contents_; |
[email protected] | 0dd3a0ab | 2011-02-18 08:17:44 | [diff] [blame] | 478 | }; |
| 479 | |
[email protected] | 674bc59 | 2011-12-20 23:00:42 | [diff] [blame] | 480 | } // namespace content |
| 481 | |
| 482 | #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ |