| Index: content/browser/frame_host/frame_tree_node.cc
|
| diff --git a/content/browser/frame_host/frame_tree_node.cc b/content/browser/frame_host/frame_tree_node.cc
|
| index 80035481e39ec266930ea396077d05cdde8ec49d..709cc26487b4005cded07a2632027f02848ff3a7 100644
|
| --- a/content/browser/frame_host/frame_tree_node.cc
|
| +++ b/content/browser/frame_host/frame_tree_node.cc
|
| @@ -35,8 +35,7 @@ FrameTreeNode::FrameTreeNode(FrameTree* frame_tree,
|
| frame_tree_node_id_(next_frame_tree_node_id_++),
|
| parent_(NULL),
|
| replication_state_(name),
|
| - effective_sandbox_flags_(SandboxFlags::NONE),
|
| - is_loading_(false) {
|
| + effective_sandbox_flags_(SandboxFlags::NONE) {
|
| }
|
|
|
| FrameTreeNode::~FrameTreeNode() {
|
| @@ -116,6 +115,28 @@ bool FrameTreeNode::IsDescendantOf(FrameTreeNode* other) const {
|
| return false;
|
| }
|
|
|
| +bool FrameTreeNode::IsLoading() const {
|
| + RenderFrameHostImpl* current_frame_host =
|
| + render_manager_.current_frame_host();
|
| + RenderFrameHostImpl* pending_frame_host =
|
| + render_manager_.pending_frame_host();
|
| +
|
| + DCHECK(current_frame_host);
|
| + // TODO(fdegans): Change the implementation logic for PlzNavigate once
|
| + // DidStartLoading and DidStopLoading are properly called.
|
| + if (pending_frame_host && pending_frame_host->is_loading())
|
| + return true;
|
| + return current_frame_host->is_loading();
|
| +}
|
| +
|
| +double FrameTreeNode::GetLoadingProgress() const {
|
| + RenderFrameHostImpl* current_frame_host =
|
| + render_manager_.current_frame_host();
|
| +
|
| + DCHECK(current_frame_host);
|
| + return current_frame_host->loading_progress();
|
| +}
|
| +
|
| bool FrameTreeNode::CommitPendingSandboxFlags() {
|
| bool did_change_flags =
|
| effective_sandbox_flags_ != replication_state_.sandbox_flags;
|
|
|