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

Unified Diff: content/browser/tab_contents/navigation_controller.cc

Issue 7791029: When the user navigates to the home page, make sure to set the RLZ string (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: When the user navigates to the home page, make sure to set the RLZ string Created 9 years, 4 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/tab_contents/navigation_controller.cc
===================================================================
--- content/browser/tab_contents/navigation_controller.cc (revision 99286)
+++ content/browser/tab_contents/navigation_controller.cc (working copy)
@@ -221,6 +221,7 @@
// static
NavigationEntry* NavigationController::CreateNavigationEntry(
const GURL& url, const GURL& referrer, PageTransition::Type transition,
+ const std::string& extra_headers,
content::BrowserContext* browser_context) {
// Allow the browser URL handler to rewrite the URL. This will, for example,
// remove "view-source:" from the beginning of the URL to get the URL that
@@ -242,6 +243,7 @@
entry->set_virtual_url(url);
entry->set_user_typed_url(url);
entry->set_update_virtual_url_with_url(reverse_on_redirect);
+ entry->set_extra_headers(extra_headers);
return entry;
}
@@ -273,7 +275,7 @@
NotificationService::current()->Notify(
content::NOTIFICATION_NAV_ENTRY_PENDING,
Source<NavigationController>(this),
- NotificationService::NoDetails());
+ Details<NavigationEntry>(entry));
NavigateToPendingEntry(NO_RELOAD);
}
@@ -483,10 +485,21 @@
void NavigationController::LoadURL(const GURL& url, const GURL& referrer,
PageTransition::Type transition) {
+ LoadURLWithHeaders(url, referrer, transition, std::string());
+}
+
+// TODO(rogerta): Remove this call and put the extra_headers argument directly
+// in LoadURL().
+void NavigationController::LoadURLWithHeaders(
+ const GURL& url,
+ const GURL& referrer,
+ PageTransition::Type transition,
+ const std::string& extra_headers) {
// The user initiated a load, we don't need to reload anymore.
needs_reload_ = false;
NavigationEntry* entry = CreateNavigationEntry(url, referrer, transition,
+ extra_headers,
browser_context_);
LoadEntry(entry);
« no previous file with comments | « content/browser/tab_contents/navigation_controller.h ('k') | content/browser/tab_contents/navigation_controller_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698