| OLD | NEW |
| 1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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 HEADLESS_PUBLIC_HEADLESS_WEB_CONTENTS_H_ | 5 #ifndef HEADLESS_PUBLIC_HEADLESS_WEB_CONTENTS_H_ |
| 6 #define HEADLESS_PUBLIC_HEADLESS_WEB_CONTENTS_H_ | 6 #define HEADLESS_PUBLIC_HEADLESS_WEB_CONTENTS_H_ |
| 7 | 7 |
| 8 #include <list> | 8 #include <list> |
| 9 #include <string> | 9 #include <string> |
| 10 #include <utility> | 10 #include <utility> |
| (...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 64 virtual void RemoveObserver(Observer* observer) = 0; | 64 virtual void RemoveObserver(Observer* observer) = 0; |
| 65 | 65 |
| 66 // Return a DevTools target corresponding to this tab. Note that this method | 66 // Return a DevTools target corresponding to this tab. Note that this method |
| 67 // won't return a valid value until Observer::DevToolsTargetReady has been | 67 // won't return a valid value until Observer::DevToolsTargetReady has been |
| 68 // signaled. | 68 // signaled. |
| 69 virtual HeadlessDevToolsTarget* GetDevToolsTarget() = 0; | 69 virtual HeadlessDevToolsTarget* GetDevToolsTarget() = 0; |
| 70 | 70 |
| 71 // Close this page. |HeadlessWebContents| object will be destroyed. | 71 // Close this page. |HeadlessWebContents| object will be destroyed. |
| 72 virtual void Close() = 0; | 72 virtual void Close() = 0; |
| 73 | 73 |
| 74 // Cancels any pending navigation. |
| 75 virtual void Stop() = 0; |
| 76 |
| 74 private: | 77 private: |
| 75 friend class HeadlessWebContentsImpl; | 78 friend class HeadlessWebContentsImpl; |
| 76 HeadlessWebContents() {} | 79 HeadlessWebContents() {} |
| 77 | 80 |
| 78 DISALLOW_COPY_AND_ASSIGN(HeadlessWebContents); | 81 DISALLOW_COPY_AND_ASSIGN(HeadlessWebContents); |
| 79 }; | 82 }; |
| 80 | 83 |
| 81 class HEADLESS_EXPORT HeadlessWebContents::Builder { | 84 class HEADLESS_EXPORT HeadlessWebContents::Builder { |
| 82 public: | 85 public: |
| 83 ~Builder(); | 86 ~Builder(); |
| (...skipping 62 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 146 GURL initial_url_ = GURL("about:blank"); | 149 GURL initial_url_ = GURL("about:blank"); |
| 147 gfx::Size window_size_; | 150 gfx::Size window_size_; |
| 148 std::list<MojoService> mojo_services_; | 151 std::list<MojoService> mojo_services_; |
| 149 | 152 |
| 150 DISALLOW_COPY_AND_ASSIGN(Builder); | 153 DISALLOW_COPY_AND_ASSIGN(Builder); |
| 151 }; | 154 }; |
| 152 | 155 |
| 153 } // namespace headless | 156 } // namespace headless |
| 154 | 157 |
| 155 #endif // HEADLESS_PUBLIC_HEADLESS_WEB_CONTENTS_H_ | 158 #endif // HEADLESS_PUBLIC_HEADLESS_WEB_CONTENTS_H_ |
| OLD | NEW |