Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(93)

Unified Diff: headless/public/headless_web_contents.h

Issue 1891843004: [headless] AddWindowTreeClient (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Added tests and changed ownership model Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: headless/public/headless_web_contents.h
diff --git a/headless/public/headless_web_contents.h b/headless/public/headless_web_contents.h
index 04ac953001d61b94e9d9bab75de4ea1a931ef0fa..8e6e49647b95a6f8e50ef5076426b3b2a98bff1e 100644
--- a/headless/public/headless_web_contents.h
+++ b/headless/public/headless_web_contents.h
@@ -43,6 +43,14 @@ class HEADLESS_EXPORT HeadlessWebContents {
virtual void AddObserver(Observer* observer) = 0;
virtual void RemoveObserver(Observer* observer) = 0;
+ // True if this WebContents was created by calling
+ // HeadlessBrowser::CreateWebContents, false otherwise (e.g. by calling
+ // window.open())
+ virtual bool IsDirectlyCreated() const = 0;
Sami 2016/04/20 16:38:50 I would suggest leaving this out, since the client
altimin 2016/04/20 17:35:25 Done.
+
+ // Close this page. |HeadlessWebContents| object will be destroyed.
+ virtual void Close() = 0;
+
private:
friend class HeadlessWebContentsImpl;
HeadlessWebContents() {}

Powered by Google App Engine
This is Rietveld 408576698