Chromium Code Reviews| Index: ios/chrome/browser/ui/toolbar/toolbar_model_delegate_ios.mm |
| diff --git a/ios/chrome/browser/ui/toolbar/toolbar_model_delegate_ios.mm b/ios/chrome/browser/ui/toolbar/toolbar_model_delegate_ios.mm |
| index e2f6d17b574225f959cbf205c4fd65a8c14210ba..9094134f93a37ce17d8b435ccbf743e7c8f2914c 100644 |
| --- a/ios/chrome/browser/ui/toolbar/toolbar_model_delegate_ios.mm |
| +++ b/ios/chrome/browser/ui/toolbar/toolbar_model_delegate_ios.mm |
| @@ -13,7 +13,6 @@ |
| #include "ios/chrome/browser/browser_state/chrome_browser_state.h" |
| #include "ios/chrome/browser/chrome_url_constants.h" |
| #include "ios/chrome/browser/pref_names.h" |
| -#include "ios/chrome/browser/reading_list/offline_url_utils.h" |
| #include "ios/chrome/browser/ssl/ios_security_state_tab_helper.h" |
| #import "ios/chrome/browser/tabs/tab.h" |
| #import "ios/chrome/browser/tabs/tab_model.h" |
| @@ -53,25 +52,7 @@ bool ToolbarModelDelegateIOS::GetURL(GURL* url) const { |
| web::NavigationItem* item = GetNavigationItem(); |
| if (!item) |
| return false; |
| - |
| - if (!ShouldDisplayURL()) { |
| - *url = GURL(); |
| - return true; |
| - } |
| - |
| - // For security reasons, we shouldn't display the https scheme and secure |
| - // padlock when there's no active ssl session. |
| - // To hide the scheme we set it http when the loaded url is offline. |
| - if (reading_list::IsOfflineURL(item->GetURL()) && |
| - item->GetVirtualURL().SchemeIs(url::kHttpsScheme)) { |
| - GURL::Replacements replacements; |
| - replacements.SetScheme(url::kHttpScheme, |
| - url::Component(0, strlen(url::kHttpScheme))); |
| - *url = item->GetVirtualURL().ReplaceComponents(replacements); |
| - return true; |
| - } |
| - |
| - *url = item->GetVirtualURL(); |
| + *url = ShouldDisplayURL() ? item->GetVirtualURL() : GURL(); |
|
Eugene But (OOO till 7-30)
2016/12/28 17:02:59
I know that you just reverting to the old code, bu
Olivier
2016/12/29 12:37:20
Done.
|
| return true; |
| } |