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

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

Issue 1148743002: Show the location bar in bookmark apps with security errors. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ssl/connection_security_helper.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/extensions/bookmark_app_browser_controller.cc
diff --git a/chrome/browser/ui/extensions/bookmark_app_browser_controller.cc b/chrome/browser/ui/extensions/bookmark_app_browser_controller.cc
index 515a070cd1613e98578dcdf48ef3a69de17a3f39..773250a19dd5658545faecfdeddabb97a0edb493 100644
--- a/chrome/browser/ui/extensions/bookmark_app_browser_controller.cc
+++ b/chrome/browser/ui/extensions/bookmark_app_browser_controller.cc
@@ -6,6 +6,7 @@
#include "base/command_line.h"
#include "chrome/browser/profiles/profile.h"
+#include "chrome/browser/ssl/connection_security_helper.h"
#include "chrome/browser/ui/browser.h"
#include "chrome/browser/ui/browser_window.h"
#include "chrome/browser/ui/host_desktop.h"
@@ -83,6 +84,11 @@ bool BookmarkAppBrowserController::ShouldShowLocationBar() {
if (web_contents->GetLastCommittedURL().is_empty())
return false;
+ ConnectionSecurityHelper::SecurityLevel security_level =
+ ConnectionSecurityHelper::GetSecurityLevelForWebContents(web_contents);
+ if (security_level == ConnectionSecurityHelper::SECURITY_ERROR)
+ return true;
+
GURL launch_url = AppLaunchInfo::GetLaunchWebURL(extension);
return !(IsSameOriginOrMoreSecure(launch_url,
web_contents->GetVisibleURL()) &&
« no previous file with comments | « chrome/browser/ssl/connection_security_helper.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698