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

Unified Diff: chrome/browser/ui/browser_commands.cc

Issue 2086423005: Using WebContents::UpdateTitleForEntry() instead of NavigationEntry::SetTitle() (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Improving comment and removing the NOTREACHED. Created 4 years, 5 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: chrome/browser/ui/browser_commands.cc
diff --git a/chrome/browser/ui/browser_commands.cc b/chrome/browser/ui/browser_commands.cc
index d3558150c8df8a94cb7e4dcf61581f88274db592..8a77489e6fc1be74f317155d4657a0a112fb6b48 100644
--- a/chrome/browser/ui/browser_commands.cc
+++ b/chrome/browser/ui/browser_commands.cc
@@ -1200,7 +1200,8 @@ void ViewSource(Browser* browser,
last_committed_entry->SetPageState(page_state.RemoveScrollOffset());
// Do not restore title, derive it from the url.
- last_committed_entry->SetTitle(base::string16());
+ view_source_contents->UpdateTitleForEntry(last_committed_entry,
+ base::string16());
// Now show view-source entry.
if (browser->CanSupportWindowFeature(Browser::FEATURE_TABSTRIP)) {

Powered by Google App Engine
This is Rietveld 408576698