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

Unified Diff: content/browser/frame_host/navigation_controller_impl.h

Issue 101573003: Add the navigation redirect-chain to Sync sessions proto for offline analysis. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Trivial change. Created 6 years, 10 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 side-by-side diff with in-line comments
Download patch
Index: content/browser/frame_host/navigation_controller_impl.h
diff --git a/content/browser/frame_host/navigation_controller_impl.h b/content/browser/frame_host/navigation_controller_impl.h
index a33f5bccd7a4c24737b40c882a1525fd3c2994ea..1fdfd7cd8bf258842efdf35ec7f3bb1d03e2e083 100644
--- a/content/browser/frame_host/navigation_controller_impl.h
+++ b/content/browser/frame_host/navigation_controller_impl.h
@@ -214,6 +214,16 @@ class CONTENT_EXPORT NavigationControllerImpl
FRIEND_TEST_ALL_PREFIXES(NavigationControllerTest,
PurgeScreenshot);
+ FRIEND_TEST_ALL_PREFIXES(NavigationControllerTest,
+ GetMergedRedirectChainNewPage);
+ FRIEND_TEST_ALL_PREFIXES(NavigationControllerTest,
+ GetMergedRedirectChainSamePage);
+ FRIEND_TEST_ALL_PREFIXES(NavigationControllerTest,
+ GetMergedRedirectChainMergeNoOverlap);
+ FRIEND_TEST_ALL_PREFIXES(NavigationControllerTest,
+ GetMergedRedirectChainMergeOneOverlap);
+ FRIEND_TEST_ALL_PREFIXES(NavigationControllerTest,
+ GetMergedRedirectChainMergeTwoOverlap);
FRIEND_TEST_ALL_PREFIXES(TimeSmoother, Basic);
FRIEND_TEST_ALL_PREFIXES(TimeSmoother, SingleDuplicate);
FRIEND_TEST_ALL_PREFIXES(TimeSmoother, ManyDuplicates);
@@ -336,6 +346,13 @@ class CONTENT_EXPORT NavigationControllerImpl
// specified |offset|. The index returned is not guaranteed to be valid.
int GetIndexForOffset(int offset) const;
+ // Produces a redirect chain by merging the active entry redirects with the
+ // redirects given in the params, taking into account the type of navigation
+ // specified in the params.
+ std::vector<GURL> GetMergedRedirectChain(
+ const FrameHostMsg_DidCommitProvisionalLoad_Params& params,
+ const std::vector<GURL>& active_entry_redirects) const;
+
// ---------------------------------------------------------------------------
// The user browser context associated with this controller.

Powered by Google App Engine
This is Rietveld 408576698