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 327 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
338 virtual void EnumerateDirectory(WebContents* web_contents, | 338 virtual void EnumerateDirectory(WebContents* web_contents, |
339 int request_id, | 339 int request_id, |
340 const base::FilePath& path) {} | 340 const base::FilePath& path) {} |
341 | 341 |
342 // Called when the renderer puts a tab into or out of fullscreen mode. | 342 // Called when the renderer puts a tab into or out of fullscreen mode. |
343 virtual void ToggleFullscreenModeForTab(WebContents* web_contents, | 343 virtual void ToggleFullscreenModeForTab(WebContents* web_contents, |
344 bool enter_fullscreen) {} | 344 bool enter_fullscreen) {} |
345 virtual bool IsFullscreenForTabOrPending( | 345 virtual bool IsFullscreenForTabOrPending( |
346 const WebContents* web_contents) const; | 346 const WebContents* web_contents) const; |
347 | 347 |
| 348 // Called when the renderer has scrolled programmatically. |
| 349 virtual void DidProgrammaticallyScroll(WebContents* web_contents, |
| 350 const gfx::Point& scroll_point) {} |
| 351 |
348 // Called when a Javascript out of memory notification is received. | 352 // Called when a Javascript out of memory notification is received. |
349 virtual void JSOutOfMemory(WebContents* web_contents) {} | 353 virtual void JSOutOfMemory(WebContents* web_contents) {} |
350 | 354 |
351 // Register a new handler for URL requests with the given scheme. | 355 // Register a new handler for URL requests with the given scheme. |
352 // |user_gesture| is true if the registration is made in the context of a user | 356 // |user_gesture| is true if the registration is made in the context of a user |
353 // gesture. | 357 // gesture. |
354 virtual void RegisterProtocolHandler(WebContents* web_contents, | 358 virtual void RegisterProtocolHandler(WebContents* web_contents, |
355 const std::string& protocol, | 359 const std::string& protocol, |
356 const GURL& url, | 360 const GURL& url, |
357 const string16& title, | 361 const string16& title, |
(...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
431 // Called when |this| is no longer the WebContentsDelegate for |source|. | 435 // Called when |this| is no longer the WebContentsDelegate for |source|. |
432 void Detach(WebContents* source); | 436 void Detach(WebContents* source); |
433 | 437 |
434 // The WebContents that this is currently a delegate for. | 438 // The WebContents that this is currently a delegate for. |
435 std::set<WebContents*> attached_contents_; | 439 std::set<WebContents*> attached_contents_; |
436 }; | 440 }; |
437 | 441 |
438 } // namespace content | 442 } // namespace content |
439 | 443 |
440 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ | 444 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ |
OLD | NEW |