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

Side by Side Diff: content/renderer/render_frame_impl.cc

Issue 2770873002: Remove ViewHostMsg_DidFirstPaintAfterLoad (Closed)
Patch Set: Updated unit tests Created 3 years, 9 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 unified diff | Download patch
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "content/renderer/render_frame_impl.h" 5 #include "content/renderer/render_frame_impl.h"
6 6
7 #include <map> 7 #include <map>
8 #include <string> 8 #include <string>
9 #include <utility> 9 #include <utility>
10 #include <vector> 10 #include <vector>
(...skipping 3675 matching lines...) Expand 10 before | Expand all | Expand 10 after
3686 } 3686 }
3687 3687
3688 if (proxy_routing_id_ != MSG_ROUTING_NONE) { 3688 if (proxy_routing_id_ != MSG_ROUTING_NONE) {
3689 // If this is a provisional frame associated with a proxy (i.e., a frame 3689 // If this is a provisional frame associated with a proxy (i.e., a frame
3690 // created for a remote-to-local navigation), swap it into the frame tree 3690 // created for a remote-to-local navigation), swap it into the frame tree
3691 // now. 3691 // now.
3692 if (!SwapIn()) 3692 if (!SwapIn())
3693 return; 3693 return;
3694 } 3694 }
3695 3695
3696 // For navigations that change the document, the browser process needs to be 3696 if (is_main_frame_ && !navigation_state->WasWithinSameDocument())
Charlie Reis 2017/03/24 16:52:01 Let's leave some comment here so that it's clear w
Saman Sami 2017/03/24 18:04:50 That's a good comment. I'll add it verbatim.
3697 // notified of the first paint of that page, so it can cancel the timer that
3698 // waits for it.
3699 if (is_main_frame_ && !navigation_state->WasWithinSameDocument()) {
3700 GetRenderWidget()->IncrementContentSourceId(); 3697 GetRenderWidget()->IncrementContentSourceId();
3701 render_view_->QueueMessage(
3702 new ViewHostMsg_DidFirstPaintAfterLoad(render_view_->routing_id_),
3703 MESSAGE_DELIVERY_POLICY_WITH_VISUAL_STATE);
3704 }
3705 3698
3706 // When we perform a new navigation, we need to update the last committed 3699 // When we perform a new navigation, we need to update the last committed
3707 // session history entry with state for the page we are leaving. Do this 3700 // session history entry with state for the page we are leaving. Do this
3708 // before updating the current history item. 3701 // before updating the current history item.
3709 SendUpdateState(); 3702 SendUpdateState();
3710 3703
3711 // Update the current history item for this frame. 3704 // Update the current history item for this frame.
3712 current_history_item_ = item; 3705 current_history_item_ = item;
3713 // Note: don't reference |item| after this point, as its value may not match 3706 // Note: don't reference |item| after this point, as its value may not match
3714 // |current_history_item_|. 3707 // |current_history_item_|.
(...skipping 3251 matching lines...) Expand 10 before | Expand all | Expand 10 after
6966 policy(info.defaultPolicy), 6959 policy(info.defaultPolicy),
6967 replaces_current_history_item(info.replacesCurrentHistoryItem), 6960 replaces_current_history_item(info.replacesCurrentHistoryItem),
6968 history_navigation_in_new_child_frame( 6961 history_navigation_in_new_child_frame(
6969 info.isHistoryNavigationInNewChildFrame), 6962 info.isHistoryNavigationInNewChildFrame),
6970 client_redirect(info.isClientRedirect), 6963 client_redirect(info.isClientRedirect),
6971 cache_disabled(info.isCacheDisabled), 6964 cache_disabled(info.isCacheDisabled),
6972 form(info.form), 6965 form(info.form),
6973 source_location(info.sourceLocation) {} 6966 source_location(info.sourceLocation) {}
6974 6967
6975 } // namespace content 6968 } // namespace content
OLDNEW
« content/browser/renderer_host/render_widget_host_impl.h ('K') | « content/common/view_messages.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698