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 eac49777a663150917ab2289073e2dd3f8dc4d6b..4ea612350f35ebecf80f0d3ec8736c5212fa620a 100644 |
| --- a/content/browser/frame_host/frame_tree_node.h |
| +++ b/content/browser/frame_host/frame_tree_node.h |
| @@ -235,7 +235,11 @@ class CONTENT_EXPORT FrameTreeNode { |
| // A RenderFrameHost in this node started loading. |
| // |to_different_document| will be true unless the load is a fragment |
| // navigation, or triggered by history.pushState/replaceState. |
| - void DidStartLoading(bool to_different_document); |
| + // |was_previously_loading| is false if the FrameTree was not loading before. |
| + // The caller is required to provide this boolean as the delegate should only |
| + // be called if the FrameTree went from non-loading to loading state. |
|
Charlie Reis
2016/02/17 05:15:28
nit: s/called/notified/
clamy
2016/02/18 17:20:26
Done.
|
| + // However, when it is called, the FrameTree should be in a loading state. |
|
Charlie Reis
2016/02/17 05:15:28
I don't understand this part. The comment could b
clamy
2016/02/17 14:42:06
Before we would call it before setting is_loading
Charlie Reis
2016/02/17 23:34:26
Acknowledged.
|
| + void DidStartLoading(bool to_different_document, bool was_previously_loading); |
| // A RenderFrameHost in this node stopped loading. |
| void DidStopLoading(); |
| @@ -257,6 +261,10 @@ class CONTENT_EXPORT FrameTreeNode { |
| // time and notifies observers. |
| void DidFocus(); |
| + // Called when the user closed the modal dialogue for BeforeUnload and |
| + // cancelled the navigation. This should stop the loads. |
|
Charlie Reis
2016/02/17 05:15:28
The comment is unclear: which loads? (There's jus
clamy
2016/02/17 14:42:06
What if there are two ongoing ones: one in the pen
Charlie Reis
2016/02/17 23:34:26
Actually, this turns out to be an interesting ques
clamy
2016/02/18 17:20:26
Actually the RFH is created before we approve the
Charlie Reis
2016/02/19 05:24:54
Ah, excellent point. And yes, we should clear the
|
| + void BeforeUnloadCanceled(); |
| + |
| private: |
| class OpenerDestroyedObserver; |