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

Unified Diff: content/browser/frame_host/frame_tree_node.h

Issue 2632633006: Implement NavigationThrottle::BLOCK_REQUEST_AND_COLLAPSE. (Closed)
Patch Set: Extend tests, fix redirects. Non-PlzNavigate version still broken. Created 3 years, 10 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: content/browser/frame_host/frame_tree_node.h
diff --git a/content/browser/frame_host/frame_tree_node.h b/content/browser/frame_host/frame_tree_node.h
index 7a4a0b9e20425f5b7d359840ccbc2d57f2dffbfc..57852cd2355fbce1ee58469dd51dea1415c9e9d5 100644
--- a/content/browser/frame_host/frame_tree_node.h
+++ b/content/browser/frame_host/frame_tree_node.h
@@ -145,6 +145,17 @@ class CONTENT_EXPORT FrameTreeNode {
return has_committed_real_load_;
}
+ // Returns whether the frame's owner element in the embedder document is
nasko 2017/03/01 20:08:04 nit: s/embedder/parent/, it is a bit more web plat
engedy 2017/04/10 14:36:41 Done.
+ // collapsed, that is, removed from the layout as if it did not exist, as per
+ // request by the client.
nasko 2017/03/01 20:08:04 What is "client" in this case? The content/ interf
engedy 2017/04/10 14:36:41 Tried to clarify.
+ bool is_collapsed_by_client() const { return is_collapsed_by_client_; }
+
+ // Sets whether to collapse the frame's owner element in the embedder
+ // document, that is, to remove it from the layout as if it did not exist, as
+ // per request by the client. Cannot be called for main frames. Only has an
+ // effect for <iframe> owner elements.
nasko 2017/03/01 20:08:04 Are there owner elements for things other than <if
engedy 2017/04/10 14:36:41 Done.
+ void SetCollapsedByClient(bool collapsed);
+
// Returns the origin of the last committed page in this frame.
// WARNING: To get the last committed origin for a particular
// RenderFrameHost, use RenderFrameHost::GetLastCommittedOrigin() instead,
@@ -363,6 +374,12 @@ class CONTENT_EXPORT FrameTreeNode {
// about:blank page.
bool has_committed_real_load_;
+ // Whether the frame's owner element in the embedder document is collapsed,
+ // that is, removed from the layout as if it did not exist, as per request
+ // from the client. Always `false` for main frames. Only works for <iframe>
+ // owner elements.
nasko 2017/03/01 20:08:04 nit: This comment is almost identical to the other
engedy 2017/04/10 14:36:41 Actually, I made this one shorter.
+ bool is_collapsed_by_client_;
+
// Track information that needs to be replicated to processes that have
// proxies for this frame.
FrameReplicationState replication_state_;
« no previous file with comments | « no previous file | content/browser/frame_host/frame_tree_node.cc » ('j') | content/browser/frame_host/frame_tree_node.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698