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

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

Issue 9383005: Add method skeleton for showing website settings. Add commandline flag. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix copyright in file headers Created 8 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: chrome/browser/ui/browser.cc
diff --git a/chrome/browser/ui/browser.cc b/chrome/browser/ui/browser.cc
index dfb836f77854e5647dd398b982345a351cf1a592..0a16091925077e22004898a6abe8371fa943cd7c 100644
--- a/chrome/browser/ui/browser.cc
+++ b/chrome/browser/ui/browser.cc
@@ -3940,10 +3940,21 @@ void Browser::OnStartDownload(WebContents* source,
CloseContents(source);
}
-void Browser::ShowPageInfo(const GURL& url,
+void Browser::ShowPageInfo(content::WebContents* web_contents,
+ const GURL& url,
const SSLStatus& ssl,
bool show_history) {
- window()->ShowPageInfo(profile_, url, ssl, show_history);
+ Profile* profile = Profile::FromBrowserContext(
+ web_contents->GetBrowserContext());
+ TabContentsWrapper* wrapper =
+ TabContentsWrapper::GetCurrentWrapperForContents(web_contents);
+
+ if (CommandLine::ForCurrentProcess()->HasSwitch(
+ switches::kEnableWebsiteSettings)) {
+ window()->ShowWebsiteSettings(profile, wrapper, url, ssl, show_history);
+ } else {
+ window()->ShowPageInfo(profile, url, ssl, show_history);
+ }
}
void Browser::ViewSourceForTab(WebContents* source, const GURL& page_url) {

Powered by Google App Engine
This is Rietveld 408576698