Chromium Code Reviews| 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 5d0a34bd366fd3875a632891acc18ac624c64080..15475c4e658d54f4145c676277ea805d37d54c77 100644 |
| --- a/content/browser/frame_host/frame_tree_node.h |
| +++ b/content/browser/frame_host/frame_tree_node.h |
| @@ -30,6 +30,12 @@ class RenderFrameHostImpl; |
| // are frame-specific (as opposed to page-specific). |
| class CONTENT_EXPORT FrameTreeNode { |
| public: |
| + // These values indicate the loading progress status. The minimum progress |
| + // value matches what Blink's ProgressTracker has traditionally used for a |
| + // minimum progress value. |
| + static const double kLoadingProgressNotStarted; |
| + static const double kLoadingProgressMinimum; |
| + static const double kLoadingProgressDone; |
| FrameTreeNode(FrameTree* frame_tree, |
| Navigator* navigator, |
| @@ -108,10 +114,25 @@ class CONTENT_EXPORT FrameTreeNode { |
| void set_is_loading(bool is_loading) { |
| is_loading_ = is_loading; |
| } |
| + |
| bool is_loading() const { |
| return is_loading_; |
| } |
| + void set_loading_progress(double loading_progress) { |
| + loading_progress_ = loading_progress; |
| + } |
| + |
| + double loading_progress() const { return loading_progress_; } |
| + |
| + void set_pending_frame_host(RenderFrameHostImpl* rfh) { |
| + pending_frame_host_ = rfh; |
| + } |
| + |
| + RenderFrameHostImpl* pending_frame_host() const { |
| + return pending_frame_host_; |
| + } |
| + |
| RenderFrameHostImpl* current_frame_host() const { |
| return render_manager_.current_frame_host(); |
| } |
| @@ -167,6 +188,12 @@ class CONTENT_EXPORT FrameTreeNode { |
| // RenderFrameHost or using a counter to balance the events out. |
| bool is_loading_; |
| + // Double value representing the frame's completion progress (from 0 to 1). |
|
nasko
2015/02/23 16:54:43
nit: s/completion/loading/
Fabrice (no longer in Chrome)
2015/02/23 20:02:06
Done.
|
| + double loading_progress_; |
| + |
| + // Pending RenderFameHostImpl whose load is being tracked. |
| + RenderFrameHostImpl* pending_frame_host_; |
| + |
| DISALLOW_COPY_AND_ASSIGN(FrameTreeNode); |
| }; |