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

Side by Side Diff: content/browser/frame_host/navigator_impl.cc

Issue 2802843003: Update CPAT protocol to send lite-page transform acceptance with ect
Patch Set: Merge with testLitePageBTF Created 3 years, 7 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/browser/frame_host/navigator_impl.h" 5 #include "content/browser/frame_host/navigator_impl.h"
6 6
7 #include <utility> 7 #include <utility>
8 8
9 #include "base/logging.h" 9 #include "base/logging.h"
10 #include "base/metrics/histogram_macros.h" 10 #include "base/metrics/histogram_macros.h"
(...skipping 345 matching lines...) Expand 10 before | Expand all | Expand 10 after
356 // Determine if Previews should be used for the navigation. 356 // Determine if Previews should be used for the navigation.
357 PreviewsState previews_state = PREVIEWS_UNSPECIFIED; 357 PreviewsState previews_state = PREVIEWS_UNSPECIFIED;
358 if (!frame_tree_node->IsMainFrame()) { 358 if (!frame_tree_node->IsMainFrame()) {
359 // For subframes, use the state of the top-level frame. 359 // For subframes, use the state of the top-level frame.
360 previews_state = frame_tree_node->frame_tree() 360 previews_state = frame_tree_node->frame_tree()
361 ->root() 361 ->root()
362 ->current_frame_host() 362 ->current_frame_host()
363 ->last_navigation_previews_state(); 363 ->last_navigation_previews_state();
364 } else if (reload_type == ReloadType::DISABLE_LOFI_MODE) { 364 } else if (reload_type == ReloadType::DISABLE_LOFI_MODE) {
365 // Disable LoFi when asked for it explicitly. 365 // Disable LoFi when asked for it explicitly.
366 previews_state = PREVIEWS_NO_TRANSFORM; 366 previews_state = PREVIEWS_OFF;
bengr 2017/05/01 16:53:14 What is the significance of this change?
367 } 367 }
368 368
369 // PlzNavigate: the RenderFrameHosts are no longer asked to navigate. 369 // PlzNavigate: the RenderFrameHosts are no longer asked to navigate.
370 if (IsBrowserSideNavigationEnabled()) { 370 if (IsBrowserSideNavigationEnabled()) {
371 navigation_data_.reset(new NavigationMetricsData(navigation_start, dest_url, 371 navigation_data_.reset(new NavigationMetricsData(navigation_start, dest_url,
372 entry.restore_type())); 372 entry.restore_type()));
373 RequestNavigation(frame_tree_node, dest_url, dest_referrer, frame_entry, 373 RequestNavigation(frame_tree_node, dest_url, dest_referrer, frame_entry,
374 entry, reload_type, previews_state, 374 entry, reload_type, previews_state,
375 is_same_document_history_load, 375 is_same_document_history_load,
376 is_history_navigation_in_new_child, navigation_start); 376 is_history_navigation_in_new_child, navigation_start);
(...skipping 919 matching lines...) Expand 10 before | Expand all | Expand 10 after
1296 if (navigation_handle) 1296 if (navigation_handle)
1297 navigation_handle->update_entry_id_for_transfer(entry->GetUniqueID()); 1297 navigation_handle->update_entry_id_for_transfer(entry->GetUniqueID());
1298 1298
1299 controller_->SetPendingEntry(std::move(entry)); 1299 controller_->SetPendingEntry(std::move(entry));
1300 if (delegate_) 1300 if (delegate_)
1301 delegate_->NotifyChangedNavigationState(content::INVALIDATE_TYPE_URL); 1301 delegate_->NotifyChangedNavigationState(content::INVALIDATE_TYPE_URL);
1302 } 1302 }
1303 } 1303 }
1304 1304
1305 } // namespace content 1305 } // namespace content
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698