Chromium Code Reviews| 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_H_ | 5 #ifndef CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_ |
| 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_ | 6 #define CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_ |
| 7 | 7 |
| 8 #include <stdint.h> | 8 #include <stdint.h> |
| 9 | 9 |
| 10 #include <memory> | 10 #include <memory> |
| (...skipping 614 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 625 virtual void DidChooseColorInColorChooser(SkColor color) = 0; | 625 virtual void DidChooseColorInColorChooser(SkColor color) = 0; |
| 626 | 626 |
| 627 // Called when the color chooser has ended. | 627 // Called when the color chooser has ended. |
| 628 virtual void DidEndColorChooser() = 0; | 628 virtual void DidEndColorChooser() = 0; |
| 629 | 629 |
| 630 // Returns true if the location bar should be focused by default rather than | 630 // Returns true if the location bar should be focused by default rather than |
| 631 // the page contents. The view calls this function when the tab is focused | 631 // the page contents. The view calls this function when the tab is focused |
| 632 // to see what it should do. | 632 // to see what it should do. |
| 633 virtual bool FocusLocationBarByDefault() = 0; | 633 virtual bool FocusLocationBarByDefault() = 0; |
| 634 | 634 |
| 635 // Does this have an opener associated with it? | 635 // Does this have an opener associated with it? |
|
Avi (use Gerrit)
2017/02/03 19:26:33
You might want to note that this is the "opener" i
| |
| 636 virtual bool HasOpener() const = 0; | 636 virtual bool HasOpener() const = 0; |
| 637 | 637 |
| 638 // Returns the opener if HasOpener() is true, or nullptr otherwise. | 638 // Returns the opener if HasOpener() is true, or nullptr otherwise. |
| 639 virtual WebContents* GetOpener() const = 0; | 639 virtual WebContents* GetOpener() const = 0; |
| 640 | 640 |
| 641 // Returns true if this WebContents was opened by another WebContents, even | |
| 642 // if the opener was suppressed. | |
|
Avi (use Gerrit)
2017/02/03 19:26:33
... even if the JavaScript opener was suppressed..
| |
| 643 virtual bool HasOriginalOpener() const = 0; | |
| 644 | |
| 645 // Returns the original opener if HasOriginalOpener() is true, or nullptr | |
| 646 // otherwise. | |
| 647 virtual WebContents* GetOriginalOpener() const = 0; | |
| 648 | |
| 641 typedef base::Callback<void( | 649 typedef base::Callback<void( |
| 642 int, /* id */ | 650 int, /* id */ |
| 643 int, /* HTTP status code */ | 651 int, /* HTTP status code */ |
| 644 const GURL&, /* image_url */ | 652 const GURL&, /* image_url */ |
| 645 const std::vector<SkBitmap>&, /* bitmaps */ | 653 const std::vector<SkBitmap>&, /* bitmaps */ |
| 646 /* The sizes in pixel of the bitmaps before they were resized due to the | 654 /* The sizes in pixel of the bitmaps before they were resized due to the |
| 647 max bitmap size passed to DownloadImage(). Each entry in the bitmaps | 655 max bitmap size passed to DownloadImage(). Each entry in the bitmaps |
| 648 vector corresponds to an entry in the sizes vector. If a bitmap was | 656 vector corresponds to an entry in the sizes vector. If a bitmap was |
| 649 resized, there should be a single returned bitmap. */ | 657 resized, there should be a single returned bitmap. */ |
| 650 const std::vector<gfx::Size>&)> | 658 const std::vector<gfx::Size>&)> |
| (...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
| 771 | 779 |
| 772 private: | 780 private: |
| 773 // This interface should only be implemented inside content. | 781 // This interface should only be implemented inside content. |
| 774 friend class WebContentsImpl; | 782 friend class WebContentsImpl; |
| 775 WebContents() {} | 783 WebContents() {} |
| 776 }; | 784 }; |
| 777 | 785 |
| 778 } // namespace content | 786 } // namespace content |
| 779 | 787 |
| 780 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_ | 788 #endif // CONTENT_PUBLIC_BROWSER_WEB_CONTENTS_H_ |
| OLD | NEW |