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 443 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
454 | 454 |
455 // Notification that the delegate should hide any showing form validation | 455 // Notification that the delegate should hide any showing form validation |
456 // message. | 456 // message. |
457 virtual void HideValidationMessage(WebContents* web_contents) {} | 457 virtual void HideValidationMessage(WebContents* web_contents) {} |
458 | 458 |
459 // Notification that the form element that triggered the validation failure | 459 // Notification that the form element that triggered the validation failure |
460 // has moved. | 460 // has moved. |
461 virtual void MoveValidationMessage(WebContents* web_contents, | 461 virtual void MoveValidationMessage(WebContents* web_contents, |
462 const gfx::Rect& anchor_in_root_view) {} | 462 const gfx::Rect& anchor_in_root_view) {} |
463 | 463 |
464 // Returns true if the WebContents is never visible. | |
465 virtual bool IsWebContentsNeverVisible(WebContents* web_contents); | |
jam
2014/04/14 22:43:01
nit: since this is on WebContentsDelegate, the "We
danakj
2014/04/14 22:47:30
Done.
| |
466 | |
464 protected: | 467 protected: |
465 virtual ~WebContentsDelegate(); | 468 virtual ~WebContentsDelegate(); |
466 | 469 |
467 private: | 470 private: |
468 friend class WebContentsImpl; | 471 friend class WebContentsImpl; |
469 | 472 |
470 // Called when |this| becomes the WebContentsDelegate for |source|. | 473 // Called when |this| becomes the WebContentsDelegate for |source|. |
471 void Attach(WebContents* source); | 474 void Attach(WebContents* source); |
472 | 475 |
473 // Called when |this| is no longer the WebContentsDelegate for |source|. | 476 // Called when |this| is no longer the WebContentsDelegate for |source|. |
474 void Detach(WebContents* source); | 477 void Detach(WebContents* source); |
475 | 478 |
476 // The WebContents that this is currently a delegate for. | 479 // The WebContents that this is currently a delegate for. |
477 std::set<WebContents*> attached_contents_; | 480 std::set<WebContents*> attached_contents_; |
478 }; | 481 }; |
479 | 482 |
480 } // namespace content | 483 } // namespace content |
481 | 484 |
482 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ | 485 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_DELEGATE_H_ |
OLD | NEW |